home *** CD-ROM | disk | FTP | other *** search
/ BBS in a Box 12 / BBS in a box XII-1.iso / Files / Tele / C / Comet2.1.3.sit / Comet / dialog.c < prev    next >
MacBinary  |  1991-10-22  |  66.6 KB  |  [TEXT/MPS ]

open in: MacOS 8.1     |     Win98     |     DOS

view JSON data     |     view as text

This file was processed as: MacBinary (archive/macBinary).

You can browse this item here: dialog.c

ConfidenceProgramDetectionMatch TypeSupport
66% dexvert Compact Compressed (Unix) (archive/compact) ext Supported
10% dexvert MacBinary (archive/macBinary) fallback Supported
1% dexvert Text File (text/txt) fallback Supported
100% file MacBinary II, Tue Oct 22 16:08:35 1991, modified Tue Oct 22 16:08:35 1991, creator 'MPS ', type ASCII, 67603 bytes "dialog.c" , at 0x10893 382 bytes resource default (weak)
99% file data default
74% TrID Macintosh plain text (MacBinary) default
25% TrID MacBinary 2 default (weak)
100% siegfried fmt/1762 MacBinary (II) default
100% lsar MacBinary default


id metadata
keyvalue
macFileType[TEXT]
macFileCreator[MPS ]



hex view
+--------+-------------------------+-------------------------+--------+--------+
|00000000| 00 08 64 69 61 6c 6f 67 | 2e 63 00 00 00 00 00 00 |..dialog|.c......|
|00000010| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000020| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000030| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000040| 00 54 45 58 54 4d 50 53 | 20 00 00 00 00 00 00 00 |.TEXTMPS| .......|
|00000050| 00 00 00 00 01 08 13 00 | 00 01 7e a5 2a 35 c3 a5 |........|..~.*5..|
|00000060| 2a 35 c3 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |*5......|........|
|00000070| 00 00 00 00 00 00 00 00 | 00 00 81 81 7d 73 00 00 |........|....}s..|
|00000080| 2f 2a 0d 09 43 6f 70 79 | 72 69 67 68 74 20 43 6f |/*..Copy|right Co|
|00000090| 72 6e 65 6c 6c 20 55 6e | 69 76 65 72 73 69 74 79 |rnell Un|iversity|
|000000a0| 20 31 39 38 36 2e 20 20 | 41 6c 6c 20 72 69 67 68 | 1986. |All righ|
|000000b0| 74 73 20 61 72 65 20 72 | 65 73 65 72 76 65 64 2e |ts are r|eserved.|
|000000c0| 0d 09 0d 09 6d 65 6e 75 | 2e 63 20 63 6f 6e 74 61 |....menu|.c conta|
|000000d0| 69 6e 73 20 72 6f 75 74 | 69 6e 65 73 20 77 68 69 |ins rout|ines whi|
|000000e0| 63 68 20 63 72 65 61 74 | 65 2c 20 6d 61 69 6e 74 |ch creat|e, maint|
|000000f0| 61 69 6e 2c 20 61 6e 64 | 20 61 6c 6c 6f 77 20 61 |ain, and| allow a|
|00000100| 63 63 65 73 73 20 74 6f | 20 0d 09 69 74 65 6d 73 |ccess to| ..items|
|00000110| 20 69 6e 20 74 68 65 20 | 4d 61 63 69 6e 74 6f 73 | in the |Macintos|
|00000120| 68 20 6d 65 6e 75 73 2e | 0d 2a 2f 0d 0d 23 69 6e |h menus.|.*/..#in|
|00000130| 63 6c 75 64 65 20 09 3c | 65 6d 2e 68 3e 0d 0d 23 |clude .<|em.h>..#|
|00000140| 69 6e 63 6c 75 64 65 09 | 3c 33 32 37 30 2e 68 3e |include.|<3270.h>|
|00000150| 0d 23 69 6e 63 6c 75 64 | 65 09 3c 72 63 6f 64 65 |.#includ|e.<rcode|
|00000160| 73 2e 68 3e 0d 23 69 6e | 63 6c 75 64 65 09 3c 68 |s.h>.#in|clude.<h|
|00000170| 31 39 2e 68 3e 0d 0d 23 | 69 6e 63 6c 75 64 65 20 |19.h>..#|include |
|00000180| 09 3c 68 31 39 2e 68 3e | 0d 23 69 6e 63 6c 75 64 |.<h19.h>|.#includ|
|00000190| 65 20 09 3c 75 74 69 6c | 2e 68 3e 0d 23 69 6e 63 |e .<util|.h>.#inc|
|000001a0| 6c 75 64 65 20 09 3c 6d | 61 63 64 65 66 73 2e 68 |lude .<m|acdefs.h|
|000001b0| 3e 0d 23 69 6e 63 6c 75 | 64 65 20 09 3c 72 65 73 |>.#inclu|de .<res|
|000001c0| 64 65 66 73 2e 68 3e 0d | 23 69 6e 63 6c 75 64 65 |defs.h>.|#include|
|000001d0| 20 09 3c 63 6e 74 6c 64 | 65 66 73 2e 68 3e 0d 23 | .<cntld|efs.h>.#|
|000001e0| 69 6e 63 6c 75 64 65 20 | 09 3c 63 6f 6e 66 69 67 |include |.<config|
|000001f0| 2e 68 3e 0d 23 69 6e 63 | 6c 75 64 65 09 22 6d 65 |.h>.#inc|lude."me|
|00000200| 6e 75 64 65 66 73 2e 68 | 22 0d 0d 23 69 6e 63 6c |nudefs.h|"..#incl|
|00000210| 75 64 65 20 3c 6e 65 74 | 2e 68 3e 09 09 09 2f 2a |ude <net|.h>.../*|
|00000220| 20 6d 65 72 67 65 64 20 | 54 43 50 20 2a 2f 0d 23 | merged |TCP */.#|
|00000230| 69 66 64 65 66 20 44 55 | 41 4c 54 43 50 0d 23 65 |ifdef DU|ALTCP.#e|
|00000240| 6e 64 69 66 0d 0d 23 69 | 66 6e 64 65 66 20 4d 41 |ndif..#i|fndef MA|
|00000250| 43 54 43 50 0d 23 69 6e | 63 6c 75 64 65 09 3c 74 |CTCP.#in|clude.<t|
|00000260| 63 70 2e 68 3e 0d 23 69 | 6e 63 6c 75 64 65 09 3c |cp.h>.#i|nclude.<|
|00000270| 74 63 70 64 65 66 73 2e | 68 3e 0d 23 65 6e 64 69 |tcpdefs.|h>.#endi|
|00000280| 66 0d 0d 65 78 74 65 72 | 6e 20 63 68 61 72 20 2a |f..exter|n char *|
|00000290| 6d 61 6c 6c 6f 63 28 29 | 3b 0d 65 78 74 65 72 6e |malloc()|;.extern|
|000002a0| 20 42 6f 6f 6c 65 61 6e | 20 61 6c 66 69 6c 74 65 | Boolean| alfilte|
|000002b0| 72 28 29 3b 0d 65 78 74 | 65 72 6e 20 73 68 6f 72 |r();.ext|ern shor|
|000002c0| 74 20 6d 6f 64 61 6c 64 | 69 61 6c 6f 67 3b 0d 0d |t modald|ialog;..|
|000002d0| 63 68 61 72 20 2a 20 6b | 65 79 73 77 65 72 72 20 |char * k|eyswerr |
|000002e0| 3d 20 22 43 61 6e 27 74 | 20 75 70 64 61 74 65 20 |= "Can't| update |
|000002f0| 6b 65 79 70 61 64 20 73 | 77 69 74 63 68 20 69 6e |keypad s|witch in|
|00000300| 20 67 6c 6f 62 61 6c 20 | 63 6f 6e 66 69 67 75 72 | global |configur|
|00000310| 61 74 69 6f 6e 22 3b 0d | 0d 0d 23 64 65 66 69 6e |ation";.|..#defin|
|00000320| 65 20 4f 4b 42 09 09 09 | 31 09 09 2f 2a 20 4f 4b |e OKB...|1../* OK|
|00000330| 20 62 75 74 74 6f 6e 20 | 2a 2f 0d 23 64 65 66 69 | button |*/.#defi|
|00000340| 6e 65 20 43 41 4e 42 09 | 09 32 09 09 2f 2a 20 63 |ne CANB.|.2../* c|
|00000350| 61 6e 63 65 6c 20 62 75 | 74 74 6f 6e 20 2a 2f 0d |ancel bu|tton */.|
|00000360| 0d 23 64 65 66 69 6e 65 | 20 53 54 4f 50 49 43 4f |.#define| STOPICO|
|00000370| 4e 09 32 09 09 09 2f 2a | 20 41 70 70 6c 65 20 41 |N.2.../*| Apple A|
|00000380| 6c 65 72 74 20 49 63 6f | 6e 20 2a 2f 0d 0d 48 61 |lert Ico|n */..Ha|
|00000390| 6e 64 6c 65 20 69 63 6f | 6e 68 3b 0d 52 65 63 74 |ndle ico|nh;.Rect|
|000003a0| 20 69 63 6f 6e 72 65 63 | 74 3b 0d 52 65 63 74 20 | iconrec|t;.Rect |
|000003b0| 6f 6b 72 65 63 74 3b 0d | 0d 2f 2a 20 77 65 20 6e |okrect;.|./* we n|
|000003c0| 65 65 64 20 74 6f 20 67 | 65 74 20 69 6e 73 69 64 |eed to g|et insid|
|000003d0| 65 20 74 68 65 20 4d 6f | 64 61 6c 44 69 61 6c 6f |e the Mo|dalDialo|
|000003e0| 67 20 65 76 65 6e 74 20 | 6c 6f 6f 70 20 74 6f 20 |g event |loop to |
|000003f0| 67 75 61 72 61 6e 74 65 | 65 20 63 79 63 6c 65 73 |guarante|e cycles|
|00000400| 20 66 6f 72 20 74 61 73 | 6b 73 2d 2d 68 65 6e 63 | for tas|ks--henc|
|00000410| 65 2c 20 2a 2f 0d 0d 70 | 61 73 63 61 6c 20 42 6f |e, */..p|ascal Bo|
|00000420| 6f 6c 65 61 6e 0d 61 6c | 66 69 6c 74 65 72 28 64 |olean.al|filter(d|
|00000430| 70 74 72 2c 20 64 65 76 | 74 2c 20 69 74 65 6d 29 |ptr, dev|t, item)|
|00000440| 0d 44 69 61 6c 6f 67 50 | 74 72 20 64 70 74 72 3b |.DialogP|tr dptr;|
|00000450| 0d 45 76 65 6e 74 52 65 | 63 6f 72 64 20 2a 20 64 |.EventRe|cord * d|
|00000460| 65 76 74 3b 0d 69 6e 74 | 20 2a 20 69 74 65 6d 3b |evt;.int| * item;|
|00000470| 0d 7b 0d 09 63 68 61 72 | 20 74 68 65 63 68 61 72 |.{..char| thechar|
|00000480| 3b 0d 0d 09 69 66 20 28 | 64 65 76 74 2d 3e 77 68 |;...if (|devt->wh|
|00000490| 61 74 20 3d 3d 20 6b 65 | 79 44 6f 77 6e 29 20 7b |at == ke|yDown) {|
|000004a0| 0d 09 09 74 68 65 63 68 | 61 72 20 3d 20 64 65 76 |...thech|ar = dev|
|000004b0| 74 2d 3e 6d 65 73 73 61 | 67 65 20 26 20 30 78 66 |t->messa|ge & 0xf|
|000004c0| 66 3b 0d 09 09 69 66 20 | 28 74 68 65 63 68 61 72 |f;...if |(thechar|
|000004d0| 20 3d 3d 20 43 52 20 7c | 7c 20 74 68 65 63 68 61 | == CR ||| thecha|
|000004e0| 72 20 3d 3d 20 30 78 30 | 33 29 20 7b 0d 09 09 09 |r == 0x0|3) {....|
|000004f0| 2a 69 74 65 6d 20 3d 20 | 31 3b 09 2f 2a 20 64 65 |*item = |1;./* de|
|00000500| 66 61 75 6c 74 20 64 6f | 77 6e 20 6f 6e 20 43 52 |fault do|wn on CR|
|00000510| 20 6f 72 20 45 6e 74 65 | 72 20 2a 2f 0d 09 09 09 | or Ente|r */....|
|00000520| 72 65 74 75 72 6e 28 54 | 52 55 45 29 3b 0d 09 09 |return(T|RUE);...|
|00000530| 7d 0d 09 09 69 66 20 28 | 64 65 76 74 2d 3e 6d 6f |}...if (|devt->mo|
|00000540| 64 69 66 69 65 72 73 20 | 26 20 63 6d 64 4b 65 79 |difiers |& cmdKey|
|00000550| 29 20 7b 0d 09 09 09 2f | 2a 20 64 6f 20 43 61 6e |) {..../|* do Can|
|00000560| 63 65 6c 20 2a 2f 0d 09 | 09 09 63 68 61 72 20 74 |cel */..|..char t|
|00000570| 68 65 63 68 61 72 3b 0d | 09 09 09 0d 09 09 09 74 |hechar;.|.......t|
|00000580| 68 65 63 68 61 72 20 3d | 20 64 65 76 74 2d 3e 6d |hechar =| devt->m|
|00000590| 65 73 73 61 67 65 20 26 | 20 30 78 66 66 3b 0d 09 |essage &| 0xff;..|
|000005a0| 09 09 73 77 69 74 63 68 | 20 28 74 68 65 63 68 61 |..switch| (thecha|
|000005b0| 72 29 20 7b 0d 09 09 09 | 09 63 61 73 65 20 27 78 |r) {....|.case 'x|
|000005c0| 27 3a 20 7b 0d 09 09 09 | 09 09 44 6c 67 43 75 74 |': {....|..DlgCut|
|000005d0| 28 64 70 74 72 29 3b 0d | 09 09 09 09 09 2a 69 74 |(dptr);.|.....*it|
|000005e0| 65 6d 20 3d 20 30 3b 09 | 0d 09 09 09 09 09 72 65 |em = 0;.|......re|
|000005f0| 74 75 72 6e 28 54 52 55 | 45 29 3b 0d 09 09 09 09 |turn(TRU|E);.....|
|00000600| 7d 0d 09 09 09 09 63 61 | 73 65 20 27 63 27 3a 20 |}.....ca|se 'c': |
|00000610| 7b 0d 09 09 09 09 09 44 | 6c 67 43 6f 70 79 28 64 |{......D|lgCopy(d|
|00000620| 70 74 72 29 3b 0d 09 09 | 09 09 09 2a 69 74 65 6d |ptr);...|...*item|
|00000630| 20 3d 20 30 3b 09 0d 09 | 09 09 09 09 72 65 74 75 | = 0;...|....retu|
|00000640| 72 6e 28 54 52 55 45 29 | 3b 0d 09 09 09 09 7d 0d |rn(TRUE)|;.....}.|
|00000650| 09 09 09 09 63 61 73 65 | 20 27 76 27 3a 20 7b 0d |....case| 'v': {.|
|00000660| 09 09 09 09 09 44 6c 67 | 50 61 73 74 65 28 64 70 |.....Dlg|Paste(dp|
|00000670| 74 72 29 3b 0d 09 09 09 | 09 09 2a 69 74 65 6d 20 |tr);....|..*item |
|00000680| 3d 20 30 3b 09 0d 09 09 | 09 09 09 72 65 74 75 72 |= 0;....|...retur|
|00000690| 6e 28 54 52 55 45 29 3b | 0d 09 09 09 09 7d 0d 09 |n(TRUE);|.....}..|
|000006a0| 09 09 09 63 61 73 65 20 | 27 2e 27 3a 20 7b 0d 09 |...case |'.': {..|
|000006b0| 09 09 09 09 2f 2a 20 43 | 6f 6d 6d 61 6e 64 2d 2e |..../* C|ommand-.|
|000006c0| 20 69 73 20 61 20 43 61 | 6e 63 65 6c 20 2a 2f 0d | is a Ca|ncel */.|
|000006d0| 09 09 09 09 09 2a 69 74 | 65 6d 20 3d 20 43 41 4e |.....*it|em = CAN|
|000006e0| 42 3b 09 0d 09 09 09 09 | 09 72 65 74 75 72 6e 28 |B;......|.return(|
|000006f0| 54 52 55 45 29 3b 0d 09 | 09 09 09 7d 0d 09 09 09 |TRUE);..|...}....|
|00000700| 7d 0d 09 09 7d 0d 09 7d | 0d 09 65 6c 73 65 20 69 |}...}..}|..else i|
|00000710| 66 20 28 64 65 76 74 2d | 3e 77 68 61 74 20 3d 3d |f (devt-|>what ==|
|00000720| 20 61 63 74 69 76 61 74 | 65 45 76 74 20 26 26 20 | activat|eEvt && |
|00000730| 64 65 76 74 2d 3e 6d 65 | 73 73 61 67 65 20 3d 3d |devt->me|ssage ==|
|00000740| 20 64 70 74 72 29 20 7b | 0d 09 09 47 72 61 66 50 | dptr) {|...GrafP|
|00000750| 74 72 20 6f 6c 64 70 6f | 72 74 3b 0d 0d 09 09 69 |tr oldpo|rt;....i|
|00000760| 66 20 28 6d 79 45 76 65 | 6e 74 2e 6d 6f 64 69 66 |f (myEve|nt.modif|
|00000770| 69 65 72 73 20 26 20 61 | 63 74 69 76 65 46 6c 61 |iers & a|ctiveFla|
|00000780| 67 29 20 7b 0d 09 09 09 | 47 65 74 50 6f 72 74 28 |g) {....|GetPort(|
|00000790| 26 6f 6c 64 70 6f 72 74 | 29 3b 0d 09 09 09 53 65 |&oldport|);....Se|
|000007a0| 74 50 6f 72 74 28 64 70 | 74 72 29 3b 0d 09 0d 09 |tPort(dp|tr);....|
|000007b0| 09 09 69 66 20 28 6f 6b | 72 65 63 74 2e 74 6f 70 |..if (ok|rect.top|
|000007c0| 20 21 3d 20 6f 6b 72 65 | 63 74 2e 62 6f 74 74 6f | != okre|ct.botto|
|000007d0| 6d 29 0d 09 09 09 09 62 | 75 74 68 69 6c 69 74 65 |m).....b|uthilite|
|000007e0| 28 26 6f 6b 72 65 63 74 | 29 3b 0d 09 0d 09 09 09 |(&okrect|);......|
|000007f0| 53 65 74 50 6f 72 74 28 | 6f 6c 64 70 6f 72 74 29 |SetPort(|oldport)|
|00000800| 3b 0d 09 09 7d 0d 09 7d | 0d 09 65 6c 73 65 20 69 |;...}..}|..else i|
|00000810| 66 20 28 64 65 76 74 2d | 3e 77 68 61 74 20 3d 3d |f (devt-|>what ==|
|00000820| 20 75 70 64 61 74 65 45 | 76 74 20 26 26 20 64 65 | updateE|vt && de|
|00000830| 76 74 2d 3e 6d 65 73 73 | 61 67 65 20 3d 3d 20 64 |vt->mess|age == d|
|00000840| 70 74 72 29 20 7b 0d 09 | 09 47 72 61 66 50 74 72 |ptr) {..|.GrafPtr|
|00000850| 20 6f 6c 64 70 6f 72 74 | 3b 0d 0d 09 09 47 65 74 | oldport|;....Get|
|00000860| 50 6f 72 74 28 26 6f 6c | 64 70 6f 72 74 29 3b 0d |Port(&ol|dport);.|
|00000870| 09 09 53 65 74 50 6f 72 | 74 28 64 70 74 72 29 3b |..SetPor|t(dptr);|
|00000880| 0d 0d 09 09 69 66 20 28 | 6f 6b 72 65 63 74 2e 74 |....if (|okrect.t|
|00000890| 6f 70 20 21 3d 20 6f 6b | 72 65 63 74 2e 62 6f 74 |op != ok|rect.bot|
|000008a0| 74 6f 6d 29 0d 09 09 09 | 62 75 74 68 69 6c 69 74 |tom)....|buthilit|
|000008b0| 65 28 26 6f 6b 72 65 63 | 74 29 3b 0d 0d 09 09 53 |e(&okrec|t);....S|
|000008c0| 65 74 50 6f 72 74 28 6f | 6c 64 70 6f 72 74 29 3b |etPort(o|ldport);|
|000008d0| 0d 09 7d 0d 09 65 6c 73 | 65 0d 09 09 64 65 66 61 |..}..els|e...defa|
|000008e0| 75 6c 74 65 76 65 6e 74 | 28 64 65 76 74 29 3b 0d |ultevent|(devt);.|
|000008f0| 09 09 0d 23 69 66 64 65 | 66 20 55 53 45 54 41 53 |...#ifde|f USETAS|
|00000900| 4b 0d 09 69 66 20 28 74 | 6b 5f 63 75 72 20 21 3d |K..if (t|k_cur !=|
|00000910| 20 4e 55 4c 4c 29 20 7b | 0d 09 09 2f 2a 20 69 66 | NULL) {|.../* if|
|00000920| 20 74 61 73 6b 69 6e 67 | 20 69 73 20 6f 6e 2c 20 | tasking| is on, |
|00000930| 64 6f 20 61 20 79 69 65 | 6c 64 20 74 6f 20 61 76 |do a yie|ld to av|
|00000940| 6f 69 64 20 74 69 6d 65 | 6f 75 74 20 2a 2f 0d 09 |oid time|out */..|
|00000950| 09 62 6b 72 64 5f 73 65 | 72 76 69 63 65 28 29 3b |.bkrd_se|rvice();|
|00000960| 0d 09 7d 0d 23 65 6e 64 | 69 66 0d 09 0d 09 72 65 |..}.#end|if....re|
|00000970| 74 75 72 6e 28 46 41 4c | 53 45 29 3b 0d 7d 0d 0d |turn(FAL|SE);.}..|
|00000980| 0d 0d 70 61 73 63 61 6c | 20 42 6f 6f 6c 65 61 6e |..pascal| Boolean|
|00000990| 0d 65 72 72 6f 72 66 69 | 6c 74 65 72 28 64 70 74 |.errorfi|lter(dpt|
|000009a0| 72 2c 20 64 65 76 74 2c | 20 69 74 65 6d 29 0d 44 |r, devt,| item).D|
|000009b0| 69 61 6c 6f 67 50 74 72 | 20 64 70 74 72 3b 0d 45 |ialogPtr| dptr;.E|
|000009c0| 76 65 6e 74 52 65 63 6f | 72 64 20 2a 20 64 65 76 |ventReco|rd * dev|
|000009d0| 74 3b 0d 69 6e 74 20 2a | 20 69 74 65 6d 3b 0d 7b |t;.int *| item;.{|
|000009e0| 0d 09 63 68 61 72 20 74 | 68 65 63 68 61 72 3b 0d |..char t|hechar;.|
|000009f0| 09 69 6e 74 20 74 79 70 | 65 3b 0d 09 48 61 6e 64 |.int typ|e;..Hand|
|00000a00| 6c 65 20 68 69 74 65 6d | 3b 0d 09 52 65 63 74 20 |le hitem|;..Rect |
|00000a10| 72 65 63 74 3b 0d 0d 09 | 69 66 20 28 74 6b 5f 63 |rect;...|if (tk_c|
|00000a20| 75 72 20 21 3d 20 4e 55 | 4c 4c 29 20 7b 0d 09 09 |ur != NU|LL) {...|
|00000a30| 2f 2a 20 69 66 20 74 61 | 73 6b 69 6e 67 20 69 73 |/* if ta|sking is|
|00000a40| 20 6f 6e 2c 20 64 6f 20 | 61 20 79 69 65 6c 64 20 | on, do |a yield |
|00000a50| 74 6f 20 61 76 6f 69 64 | 20 74 69 6d 65 6f 75 74 |to avoid| timeout|
|00000a60| 20 2a 2f 0d 09 09 62 6b | 72 64 5f 73 65 72 76 69 | */...bk|rd_servi|
|00000a70| 63 65 28 29 3b 0d 09 7d | 0d 09 69 66 20 28 64 65 |ce();..}|..if (de|
|00000a80| 76 74 2d 3e 77 68 61 74 | 20 3d 3d 20 6b 65 79 44 |vt->what| == keyD|
|00000a90| 6f 77 6e 29 20 7b 0d 09 | 09 74 68 65 63 68 61 72 |own) {..|.thechar|
|00000aa0| 20 3d 20 64 65 76 74 2d | 3e 6d 65 73 73 61 67 65 | = devt-|>message|
|00000ab0| 20 26 20 30 78 66 66 3b | 0d 09 09 69 66 20 28 74 | & 0xff;|...if (t|
|00000ac0| 68 65 63 68 61 72 20 3d | 3d 20 43 52 20 7c 7c 20 |hechar =|= CR || |
|00000ad0| 74 68 65 63 68 61 72 20 | 3d 3d 20 30 78 30 33 29 |thechar |== 0x03)|
|00000ae0| 20 7b 0d 09 09 09 2a 69 | 74 65 6d 20 3d 20 31 3b | {....*i|tem = 1;|
|00000af0| 09 2f 2a 20 64 65 66 61 | 75 6c 74 20 64 6f 77 6e |./* defa|ult down|
|00000b00| 20 6f 6e 20 43 52 20 6f | 72 20 45 6e 74 65 72 20 | on CR o|r Enter |
|00000b10| 2a 2f 0d 09 09 09 72 65 | 74 75 72 6e 28 54 52 55 |*/....re|turn(TRU|
|00000b20| 45 29 3b 0d 09 09 7d 0d | 09 7d 0d 09 65 6c 73 65 |E);...}.|.}..else|
|00000b30| 20 69 66 20 28 64 65 76 | 74 2d 3e 77 68 61 74 20 | if (dev|t->what |
|00000b40| 3d 3d 20 61 63 74 69 76 | 61 74 65 45 76 74 20 26 |== activ|ateEvt &|
|00000b50| 26 20 64 65 76 74 2d 3e | 6d 65 73 73 61 67 65 20 |& devt->|message |
|00000b60| 3d 3d 20 64 70 74 72 29 | 20 7b 0d 09 09 47 72 61 |== dptr)| {...Gra|
|00000b70| 66 50 74 72 20 6f 6c 64 | 70 6f 72 74 3b 0d 0d 09 |fPtr old|port;...|
|00000b80| 09 69 66 20 28 6d 79 45 | 76 65 6e 74 2e 6d 6f 64 |.if (myE|vent.mod|
|00000b90| 69 66 69 65 72 73 20 26 | 20 61 63 74 69 76 65 46 |ifiers &| activeF|
|00000ba0| 6c 61 67 29 20 7b 0d 09 | 09 09 47 65 74 50 6f 72 |lag) {..|..GetPor|
|00000bb0| 74 28 26 6f 6c 64 70 6f | 72 74 29 3b 0d 09 09 09 |t(&oldpo|rt);....|
|00000bc0| 53 65 74 50 6f 72 74 28 | 64 70 74 72 29 3b 0d 09 |SetPort(|dptr);..|
|00000bd0| 0d 09 09 09 47 65 74 44 | 49 74 65 6d 28 64 70 74 |....GetD|Item(dpt|
|00000be0| 72 2c 20 4f 4b 42 2c 20 | 26 74 79 70 65 2c 20 26 |r, OKB, |&type, &|
|00000bf0| 68 69 74 65 6d 2c 20 26 | 72 65 63 74 29 3b 0d 09 |hitem, &|rect);..|
|00000c00| 09 09 62 75 74 68 69 6c | 69 74 65 28 26 72 65 63 |..buthil|ite(&rec|
|00000c10| 74 29 3b 0d 09 09 09 09 | 2f 2a 20 68 69 6c 69 74 |t);.....|/* hilit|
|00000c20| 65 20 22 4f 4b 22 20 6b | 65 79 20 2a 2f 0d 09 09 |e "OK" k|ey */...|
|00000c30| 09 50 6c 6f 74 49 63 6f | 6e 28 26 69 63 6f 6e 72 |.PlotIco|n(&iconr|
|00000c40| 65 63 74 2c 20 69 63 6f | 6e 68 29 3b 20 0d 09 0d |ect, ico|nh); ...|
|00000c50| 09 09 09 53 65 74 50 6f | 72 74 28 6f 6c 64 70 6f |...SetPo|rt(oldpo|
|00000c60| 72 74 29 3b 0d 09 09 7d | 0d 09 7d 0d 09 65 6c 73 |rt);...}|..}..els|
|00000c70| 65 20 69 66 20 28 64 65 | 76 74 2d 3e 77 68 61 74 |e if (de|vt->what|
|00000c80| 20 3d 3d 20 75 70 64 61 | 74 65 45 76 74 20 26 26 | == upda|teEvt &&|
|00000c90| 20 64 65 76 74 2d 3e 6d | 65 73 73 61 67 65 20 3d | devt->m|essage =|
|00000ca0| 3d 20 64 70 74 72 29 20 | 7b 0d 09 09 47 72 61 66 |= dptr) |{...Graf|
|00000cb0| 50 74 72 20 6f 6c 64 70 | 6f 72 74 3b 0d 0d 09 09 |Ptr oldp|ort;....|
|00000cc0| 47 65 74 50 6f 72 74 28 | 26 6f 6c 64 70 6f 72 74 |GetPort(|&oldport|
|00000cd0| 29 3b 0d 09 09 53 65 74 | 50 6f 72 74 28 64 70 74 |);...Set|Port(dpt|
|00000ce0| 72 29 3b 0d 0d 09 09 47 | 65 74 44 49 74 65 6d 28 |r);....G|etDItem(|
|00000cf0| 64 70 74 72 2c 20 4f 4b | 42 2c 20 26 74 79 70 65 |dptr, OK|B, &type|
|00000d00| 2c 20 26 68 69 74 65 6d | 2c 20 26 72 65 63 74 29 |, &hitem|, &rect)|
|00000d10| 3b 0d 09 09 62 75 74 68 | 69 6c 69 74 65 28 26 72 |;...buth|ilite(&r|
|00000d20| 65 63 74 29 3b 0d 09 09 | 09 2f 2a 20 68 69 6c 69 |ect);...|./* hili|
|00000d30| 74 65 20 22 4f 4b 22 20 | 6b 65 79 20 2a 2f 0d 09 |te "OK" |key */..|
|00000d40| 09 50 6c 6f 74 49 63 6f | 6e 28 26 69 63 6f 6e 72 |.PlotIco|n(&iconr|
|00000d50| 65 63 74 2c 20 69 63 6f | 6e 68 29 3b 20 0d 0d 09 |ect, ico|nh); ...|
|00000d60| 09 53 65 74 50 6f 72 74 | 28 6f 6c 64 70 6f 72 74 |.SetPort|(oldport|
|00000d70| 29 3b 0d 09 7d 0d 09 65 | 6c 73 65 0d 09 09 64 65 |);..}..e|lse...de|
|00000d80| 66 61 75 6c 74 65 76 65 | 6e 74 28 64 65 76 74 29 |faulteve|nt(devt)|
|00000d90| 3b 0d 09 72 65 74 75 72 | 6e 28 46 41 4c 53 45 29 |;..retur|n(FALSE)|
|00000da0| 3b 0d 7d 0d 0d 0d 73 68 | 6f 72 74 20 69 6e 65 72 |;.}...sh|ort iner|
|00000db0| 72 6f 72 3b 0d 0d 23 64 | 65 66 69 6e 65 20 45 52 |ror;..#d|efine ER|
|00000dc0| 52 54 45 58 54 09 32 0d | 0d 65 72 72 6f 72 28 73 |RTEXT.2.|.error(s|
|00000dd0| 74 72 69 6e 67 29 0d 63 | 68 61 72 20 2a 20 73 74 |tring).c|har * st|
|00000de0| 72 69 6e 67 3b 0d 7b 0d | 09 44 69 61 6c 6f 67 50 |ring;.{.|.DialogP|
|00000df0| 74 72 20 65 72 72 64 70 | 74 72 3b 0d 09 69 6e 74 |tr errdp|tr;..int|
|00000e00| 20 6d 6f 64 61 6c 73 74 | 61 74 65 3b 0d 09 69 6e | modalst|ate;..in|
|00000e10| 74 09 69 74 65 6d 5f 69 | 64 3b 0d 09 47 72 61 66 |t.item_i|d;..Graf|
|00000e20| 50 74 72 09 6f 70 6f 72 | 74 3b 0d 09 69 6e 74 09 |Ptr.opor|t;..int.|
|00000e30| 09 09 74 79 70 65 3b 09 | 09 09 2f 2a 20 67 65 6e |..type;.|../* gen|
|00000e40| 65 72 61 6c 20 70 75 72 | 70 6f 73 65 20 67 65 74 |eral pur|pose get|
|00000e50| 64 69 74 65 6d 20 76 61 | 72 73 20 2a 2f 0d 09 48 |ditem va|rs */..H|
|00000e60| 61 6e 64 6c 65 09 09 68 | 69 74 65 6d 3b 0d 09 52 |andle..h|item;..R|
|00000e70| 65 63 74 09 09 72 65 63 | 74 3b 0d 09 0d 09 69 66 |ect..rec|t;....if|
|00000e80| 20 28 69 6e 65 72 72 6f | 72 29 20 7b 0d 09 09 53 | (inerro|r) {...S|
|00000e90| 79 73 42 65 65 70 28 35 | 29 3b 0d 09 09 72 65 74 |ysBeep(5|);...ret|
|00000ea0| 75 72 6e 28 2d 31 29 3b | 0d 09 7d 0d 09 0d 09 6d |urn(-1);|..}....m|
|00000eb0| 6f 64 61 6c 73 74 61 74 | 65 20 3d 20 6d 6f 64 61 |odalstat|e = moda|
|00000ec0| 6c 64 69 61 6c 6f 67 3b | 0d 09 0d 09 69 66 20 28 |ldialog;|....if (|
|00000ed0| 63 68 6b 62 61 63 6b 67 | 72 6f 75 6e 64 28 29 29 |chkbackg|round())|
|00000ee0| 0d 09 09 72 65 74 75 72 | 6e 28 2d 31 29 3b 0d 0d |...retur|n(-1);..|
|00000ef0| 09 63 74 6f 70 28 73 74 | 72 69 6e 67 29 3b 0d 09 |.ctop(st|ring);..|
|00000f00| 0d 09 47 65 74 50 6f 72 | 74 28 26 6f 70 6f 72 74 |..GetPor|t(&oport|
|00000f10| 29 3b 0d 09 69 6e 65 72 | 72 6f 72 20 3d 20 54 52 |);..iner|ror = TR|
|00000f20| 55 45 3b 0d 0d 09 69 66 | 20 28 28 65 72 72 64 70 |UE;...if| ((errdp|
|00000f30| 74 72 20 3d 20 47 65 74 | 4e 65 77 44 69 61 6c 6f |tr = Get|NewDialo|
|00000f40| 67 28 41 4c 45 52 52 4f | 52 2c 20 4e 55 4c 4c 2c |g(ALERRO|R, NULL,|
|00000f50| 20 28 57 69 6e 64 6f 77 | 50 74 72 29 20 28 2d 31 | (Window|Ptr) (-1|
|00000f60| 29 29 29 20 3d 3d 20 4e | 55 4c 4c 29 20 7b 0d 09 |))) == N|ULL) {..|
|00000f70| 09 70 74 6f 63 28 73 74 | 72 69 6e 67 29 3b 0d 09 |.ptoc(st|ring);..|
|00000f80| 09 69 6e 65 72 72 6f 72 | 20 3d 20 46 41 4c 53 45 |.inerror| = FALSE|
|00000f90| 3b 0d 09 09 72 65 74 75 | 72 6e 28 2d 31 29 3b 0d |;...retu|rn(-1);.|
|00000fa0| 09 7d 0d 0d 09 47 65 74 | 44 49 74 65 6d 28 65 72 |.}...Get|DItem(er|
|00000fb0| 72 64 70 74 72 2c 20 45 | 52 52 54 45 58 54 2c 20 |rdptr, E|RRTEXT, |
|00000fc0| 26 74 79 70 65 2c 20 26 | 68 69 74 65 6d 2c 20 26 |&type, &|hitem, &|
|00000fd0| 72 65 63 74 29 3b 0d 09 | 53 65 74 49 54 65 78 74 |rect);..|SetIText|
|00000fe0| 28 68 69 74 65 6d 2c 20 | 73 74 72 69 6e 67 29 3b |(hitem, |string);|
|00000ff0| 0d 09 0d 09 65 6d 77 64 | 65 61 63 74 69 76 61 74 |....emwd|eactivat|
|00001000| 65 28 29 3b 0d 09 0d 09 | 63 65 6e 74 65 72 77 69 |e();....|centerwi|
|00001010| 6e 64 28 65 72 72 64 70 | 74 72 29 3b 0d 09 0d 09 |nd(errdp|tr);....|
|00001020| 6d 6f 64 61 6c 64 69 61 | 6c 6f 67 20 3d 20 54 52 |modaldia|log = TR|
|00001030| 55 45 3b 0d 09 53 65 74 | 43 75 72 73 6f 72 28 26 |UE;..Set|Cursor(&|
|00001040| 61 72 72 6f 77 29 3b 0d | 09 73 68 6f 77 63 75 72 |arrow);.|.showcur|
|00001050| 73 6f 72 28 29 3b 0d 09 | 53 65 74 50 6f 72 74 28 |sor();..|SetPort(|
|00001060| 65 72 72 64 70 74 72 29 | 3b 0d 0d 09 69 63 6f 6e |errdptr)|;...icon|
|00001070| 68 20 3d 20 47 65 74 49 | 63 6f 6e 28 53 54 4f 50 |h = GetI|con(STOP|
|00001080| 49 43 4f 4e 29 3b 0d 09 | 69 63 6f 6e 72 65 63 74 |ICON);..|iconrect|
|00001090| 2e 74 6f 70 20 3d 20 31 | 30 3b 0d 09 69 63 6f 6e |.top = 1|0;..icon|
|000010a0| 72 65 63 74 2e 6c 65 66 | 74 20 3d 20 32 30 3b 0d |rect.lef|t = 20;.|
|000010b0| 09 69 63 6f 6e 72 65 63 | 74 2e 62 6f 74 74 6f 6d |.iconrec|t.bottom|
|000010c0| 20 3d 20 34 32 3b 0d 09 | 69 63 6f 6e 72 65 63 74 | = 42;..|iconrect|
|000010d0| 2e 72 69 67 68 74 20 3d | 20 35 32 3b 0d 09 50 6c |.right =| 52;..Pl|
|000010e0| 6f 74 49 63 6f 6e 28 26 | 69 63 6f 6e 72 65 63 74 |otIcon(&|iconrect|
|000010f0| 2c 20 69 63 6f 6e 68 29 | 3b 20 0d 09 0d 09 47 65 |, iconh)|; ....Ge|
|00001100| 74 44 49 74 65 6d 28 65 | 72 72 64 70 74 72 2c 20 |tDItem(e|rrdptr, |
|00001110| 4f 4b 42 2c 20 26 74 79 | 70 65 2c 20 26 68 69 74 |OKB, &ty|pe, &hit|
|00001120| 65 6d 2c 20 26 72 65 63 | 74 29 3b 0d 09 62 75 74 |em, &rec|t);..but|
|00001130| 68 69 6c 69 74 65 28 26 | 72 65 63 74 29 3b 0d 09 |hilite(&|rect);..|
|00001140| 09 2f 2a 20 68 69 6c 69 | 74 65 20 22 4f 4b 22 20 |./* hili|te "OK" |
|00001150| 6b 65 79 20 2a 2f 0d 0d | 09 77 68 69 6c 65 20 28 |key */..|.while (|
|00001160| 31 29 20 7b 0d 09 09 4d | 6f 64 61 6c 44 69 61 6c |1) {...M|odalDial|
|00001170| 6f 67 28 28 50 72 6f 63 | 50 74 72 29 20 65 72 72 |og((Proc|Ptr) err|
|00001180| 6f 72 66 69 6c 74 65 72 | 2c 20 26 69 74 65 6d 5f |orfilter|, &item_|
|00001190| 69 64 29 3b 0d 09 09 69 | 66 20 28 69 74 65 6d 5f |id);...i|f (item_|
|000011a0| 69 64 20 3d 3d 20 4f 4b | 42 29 0d 09 09 09 62 72 |id == OK|B)....br|
|000011b0| 65 61 6b 3b 0d 09 7d 09 | 0d 0d 09 53 65 74 50 6f |eak;..}.|...SetPo|
|000011c0| 72 74 28 6f 70 6f 72 74 | 29 3b 0d 09 44 69 73 70 |rt(oport|);..Disp|
|000011d0| 6f 73 44 69 61 6c 6f 67 | 28 65 72 72 64 70 74 72 |osDialog|(errdptr|
|000011e0| 29 3b 0d 09 70 74 6f 63 | 28 73 74 72 69 6e 67 29 |);..ptoc|(string)|
|000011f0| 3b 0d 09 6d 6f 64 61 6c | 64 69 61 6c 6f 67 20 3d |;..modal|dialog =|
|00001200| 20 6d 6f 64 61 6c 73 74 | 61 74 65 3b 0d 09 0d 09 | modalst|ate;....|
|00001210| 69 6e 65 72 72 6f 72 20 | 3d 20 46 41 4c 53 45 3b |inerror |= FALSE;|
|00001220| 0d 7d 0d 0d 0d 73 74 6f | 70 65 72 72 6f 72 28 73 |.}...sto|perror(s|
|00001230| 74 72 69 6e 67 29 0d 63 | 68 61 72 20 2a 20 73 74 |tring).c|har * st|
|00001240| 72 69 6e 67 3b 0d 7b 0d | 09 65 72 72 6f 72 28 73 |ring;.{.|.error(s|
|00001250| 74 72 69 6e 67 29 3b 0d | 7d 0d 0d 72 65 73 65 72 |tring);.|}..reser|
|00001260| 72 6f 72 28 29 0d 7b 0d | 09 69 66 20 28 52 65 73 |ror().{.|.if (Res|
|00001270| 45 72 72 6f 72 28 29 29 | 20 7b 0d 09 09 65 72 72 |Error())| {...err|
|00001280| 6f 72 28 22 52 65 73 6f | 75 72 63 65 20 65 72 72 |or("Reso|urce err|
|00001290| 6f 72 22 29 3b 0d 09 09 | 72 65 74 75 72 6e 28 2d |or");...|return(-|
|000012a0| 31 29 3b 0d 09 7d 0d 7d | 0d 0d 0d 2f 2a 20 0d 20 |1);..}.}|.../* . |
|000012b0| 2a 20 20 64 69 73 70 6c | 61 79 20 74 65 78 74 20 |* displ|ay text |
|000012c0| 69 6e 20 61 20 77 69 6e | 64 6f 77 3b 20 62 6f 74 |in a win|dow; bot|
|000012d0| 68 20 61 72 65 20 74 61 | 6b 65 6e 20 66 72 6f 6d |h are ta|ken from|
|000012e0| 20 72 65 73 6f 75 72 63 | 65 20 66 69 6c 65 2c 20 | resourc|e file, |
|000012f0| 77 69 74 68 20 74 68 65 | 20 0d 20 2a 20 20 61 73 |with the| . * as|
|00001300| 73 75 6d 70 74 69 6f 6e | 20 74 68 65 20 69 64 20 |sumption| the id |
|00001310| 6e 75 6d 62 65 72 20 69 | 73 20 74 68 65 20 73 61 |number i|s the sa|
|00001320| 6d 65 20 66 6f 72 20 62 | 6f 74 68 0d 20 2a 2f 0d |me for b|oth. */.|
|00001330| 0d 68 65 6c 70 77 69 6e | 64 6f 77 28 72 65 73 69 |.helpwin|dow(resi|
|00001340| 64 2c 20 66 6f 6e 74 2c | 20 66 6f 6e 74 73 69 7a |d, font,| fontsiz|
|00001350| 65 29 0d 69 6e 74 20 72 | 65 73 69 64 3b 0d 69 6e |e).int r|esid;.in|
|00001360| 74 20 66 6f 6e 74 3b 0d | 69 6e 74 20 66 6f 6e 74 |t font;.|int font|
|00001370| 73 69 7a 65 3b 0d 7b 0d | 09 6c 6f 6e 67 20 6c 65 |size;.{.|.long le|
|00001380| 6e 67 74 68 3b 0d 09 48 | 61 6e 64 6c 65 20 74 68 |ngth;..H|andle th|
|00001390| 65 74 65 78 74 3b 0d 0d | 23 69 66 64 65 66 20 55 |etext;..|#ifdef U|
|000013a0| 53 45 54 45 58 54 57 49 | 4e 44 4f 57 53 0d 09 69 |SETEXTWI|NDOWS..i|
|000013b0| 66 20 28 6f 70 74 6b 65 | 79 64 6f 77 6e 28 29 20 |f (optke|ydown() |
|000013c0| 26 26 20 6b 65 79 64 70 | 20 21 3d 20 4e 55 4c 4c |&& keydp| != NULL|
|000013d0| 20 26 26 20 6b 65 79 64 | 70 2d 3e 74 65 78 74 77 | && keyd|p->textw|
|000013e0| 69 6e 64 6f 77 20 21 3d | 20 4e 55 4c 4c 29 20 7b |indow !=| NULL) {|
|000013f0| 0d 09 09 2f 2a 20 64 75 | 6d 70 20 69 6e 74 6f 20 |.../* du|mp into |
|00001400| 61 20 74 65 78 74 20 77 | 69 6e 64 6f 77 20 2a 2f |a text w|indow */|
|00001410| 0d 09 09 68 65 6c 70 74 | 65 78 74 77 69 6e 64 6f |...helpt|extwindo|
|00001420| 77 28 72 65 73 69 64 29 | 3b 0d 09 09 72 65 74 75 |w(resid)|;...retu|
|00001430| 72 6e 3b 0d 09 7d 0d 23 | 65 6e 64 69 66 0d 0d 09 |rn;..}.#|endif...|
|00001440| 74 68 65 74 65 78 74 20 | 3d 20 47 65 74 52 65 73 |thetext |= GetRes|
|00001450| 6f 75 72 63 65 28 27 54 | 45 58 54 27 2c 20 28 73 |ource('T|EXT', (s|
|00001460| 68 6f 72 74 29 20 72 65 | 73 69 64 29 3b 0d 09 69 |hort) re|sid);..i|
|00001470| 66 20 28 74 68 65 74 65 | 78 74 20 3d 3d 20 4e 55 |f (thete|xt == NU|
|00001480| 4c 4c 29 0d 09 09 72 65 | 74 75 72 6e 28 2d 31 29 |LL)...re|turn(-1)|
|00001490| 3b 0d 09 48 4c 6f 63 6b | 28 74 68 65 74 65 78 74 |;..HLock|(thetext|
|000014a0| 29 3b 0d 09 6c 65 6e 67 | 74 68 20 3d 20 47 65 74 |);..leng|th = Get|
|000014b0| 48 61 6e 64 6c 65 53 69 | 7a 65 28 74 68 65 74 65 |HandleSi|ze(thete|
|000014c0| 78 74 29 3b 0d 0d 09 66 | 69 6c 6c 77 69 6e 64 6f |xt);...f|illwindo|
|000014d0| 77 28 72 65 73 69 64 2c | 20 2a 74 68 65 74 65 78 |w(resid,| *thetex|
|000014e0| 74 20 2b 20 34 2c 20 28 | 6c 6f 6e 67 29 20 28 6c |t + 4, (|long) (l|
|000014f0| 65 6e 67 74 68 20 2d 20 | 34 29 2c 20 66 6f 6e 74 |ength - |4), font|
|00001500| 2c 20 66 6f 6e 74 73 69 | 7a 65 2c 20 30 4c 29 3b |, fontsi|ze, 0L);|
|00001510| 0d 09 09 2f 2a 20 54 45 | 58 54 20 74 79 70 65 73 |.../* TE|XT types|
|00001520| 20 68 61 76 65 20 34 20 | 62 79 74 65 73 20 6f 66 | have 4 |bytes of|
|00001530| 20 6c 65 6e 67 74 68 20 | 69 6e 20 74 68 65 6d 20 | length |in them |
|00001540| 2a 2f 0d 09 48 55 6e 6c | 6f 63 6b 28 74 68 65 74 |*/..HUnl|ock(thet|
|00001550| 65 78 74 29 3b 0d 7d 0d | 0d 0d 2f 2a 20 67 65 74 |ext);.}.|../* get|
|00001560| 20 61 20 77 69 6e 64 6f | 77 20 77 69 74 68 20 74 | a windo|w with t|
|00001570| 68 65 20 73 70 65 63 69 | 66 69 65 64 20 69 64 20 |he speci|fied id |
|00001580| 61 6e 64 20 66 69 6c 6c | 20 77 69 74 68 20 74 68 |and fill| with th|
|00001590| 65 20 74 65 78 74 20 2a | 2f 0d 0d 66 69 6c 6c 77 |e text *|/..fillw|
|000015a0| 69 6e 64 6f 77 28 72 65 | 73 69 64 2c 20 74 68 65 |indow(re|sid, the|
|000015b0| 74 65 78 74 2c 20 6c 65 | 6e 67 74 68 2c 20 66 6f |text, le|ngth, fo|
|000015c0| 6e 74 2c 20 66 6f 6e 74 | 73 69 7a 65 2c 20 77 61 |nt, font|size, wa|
|000015d0| 69 74 66 6f 72 29 0d 69 | 6e 74 20 72 65 73 69 64 |itfor).i|nt resid|
|000015e0| 3b 0d 63 68 61 72 20 2a | 20 74 68 65 74 65 78 74 |;.char *| thetext|
|000015f0| 3b 0d 6c 6f 6e 67 20 6c | 65 6e 67 74 68 3b 0d 69 |;.long l|ength;.i|
|00001600| 6e 74 20 66 6f 6e 74 3b | 0d 69 6e 74 20 66 6f 6e |nt font;|.int fon|
|00001610| 74 73 69 7a 65 3b 0d 6c | 6f 6e 67 20 77 61 69 74 |tsize;.l|ong wait|
|00001620| 66 6f 72 3b 09 2f 2a 4b | 53 2a 2f 0d 7b 0d 09 52 |for;./*K|S*/.{..R|
|00001630| 65 63 74 20 62 6f 75 6e | 64 73 3b 0d 09 52 65 63 |ect boun|ds;..Rec|
|00001640| 74 20 6e 75 6c 6c 72 65 | 63 74 3b 0d 09 47 72 61 |t nullre|ct;..Gra|
|00001650| 66 50 74 72 20 6f 68 65 | 6c 70 70 6f 72 74 3b 0d |fPtr ohe|lpport;.|
|00001660| 09 69 6e 74 20 6d 6f 64 | 61 6c 73 74 61 74 65 3b |.int mod|alstate;|
|00001670| 0d 20 20 20 20 46 6f 6e | 74 49 6e 66 6f 20 20 66 |. Fon|tInfo f|
|00001680| 69 6e 66 6f 3b 0d 09 0d | 09 69 66 20 28 63 68 6b |info;...|.if (chk|
|00001690| 62 61 63 6b 67 72 6f 75 | 6e 64 28 29 29 20 7b 0d |backgrou|nd()) {.|
|000016a0| 09 09 72 65 74 75 72 6e | 3b 0d 09 7d 0d 09 69 66 |..return|;..}..if|
|000016b0| 20 28 68 65 6c 70 77 69 | 6e 64 20 21 3d 20 4e 55 | (helpwi|nd != NU|
|000016c0| 4c 4c 29 0d 09 09 66 69 | 6c 6c 77 69 6e 64 63 6c |LL)...fi|llwindcl|
|000016d0| 6f 73 65 28 29 3b 0d 09 | 09 0d 09 47 65 74 50 6f |ose();..|...GetPo|
|000016e0| 72 74 28 26 6f 68 65 6c | 70 70 6f 72 74 29 3b 0d |rt(&ohel|pport);.|
|000016f0| 0d 09 69 66 20 28 20 28 | 68 65 6c 70 77 69 6e 64 |..if ( (|helpwind|
|00001700| 20 3d 20 47 65 74 4e 65 | 77 57 69 6e 64 6f 77 28 | = GetNe|wWindow(|
|00001710| 72 65 73 69 64 2c 20 28 | 50 74 72 29 20 4e 55 4c |resid, (|Ptr) NUL|
|00001720| 4c 2c 20 28 57 69 6e 64 | 6f 77 50 74 72 29 20 28 |L, (Wind|owPtr) (|
|00001730| 2d 31 29 29 20 29 20 3d | 3d 20 4e 55 4c 4c 29 0d |-1)) ) =|= NULL).|
|00001740| 09 09 69 66 20 28 20 28 | 68 65 6c 70 77 69 6e 64 |..if ( (|helpwind|
|00001750| 20 3d 20 47 65 74 4e 65 | 77 57 69 6e 64 6f 77 28 | = GetNe|wWindow(|
|00001760| 31 30 30 30 20 2b 20 66 | 6f 6e 74 73 69 7a 65 2c |1000 + f|ontsize,|
|00001770| 20 28 50 74 72 29 20 4e | 55 4c 4c 2c 20 28 57 69 | (Ptr) N|ULL, (Wi|
|00001780| 6e 64 6f 77 50 74 72 29 | 20 28 2d 31 29 29 20 29 |ndowPtr)| (-1)) )|
|00001790| 20 3d 3d 20 4e 55 4c 4c | 29 0d 09 09 09 69 66 20 | == NULL|)....if |
|000017a0| 28 20 28 68 65 6c 70 77 | 69 6e 64 20 3d 20 47 65 |( (helpw|ind = Ge|
|000017b0| 74 4e 65 77 57 69 6e 64 | 6f 77 28 31 30 30 30 2c |tNewWind|ow(1000,|
|000017c0| 20 28 50 74 72 29 20 4e | 55 4c 4c 2c 20 28 57 69 | (Ptr) N|ULL, (Wi|
|000017d0| 6e 64 6f 77 50 74 72 29 | 20 28 2d 31 29 29 20 29 |ndowPtr)| (-1)) )|
|000017e0| 20 3d 3d 20 4e 55 4c 4c | 29 0d 09 09 09 09 72 65 | == NULL|).....re|
|000017f0| 74 75 72 6e 28 2d 31 29 | 3b 0d 09 09 09 0d 09 69 |turn(-1)|;......i|
|00001800| 66 20 28 6b 65 79 64 70 | 20 21 3d 20 4e 55 4c 4c |f (keydp| != NULL|
|00001810| 29 20 7b 0d 09 09 67 65 | 74 63 6f 6e 74 65 78 74 |) {...ge|tcontext|
|00001820| 28 6b 65 79 64 70 29 3b | 0d 09 09 65 6d 77 64 65 |(keydp);|...emwde|
|00001830| 61 63 74 69 76 61 74 65 | 28 29 3b 0d 09 7d 0d 09 |activate|();..}..|
|00001840| 63 65 6e 74 65 72 77 69 | 6e 64 28 68 65 6c 70 77 |centerwi|nd(helpw|
|00001850| 69 6e 64 29 3b 0d 09 0d | 09 6d 6f 64 61 6c 73 74 |ind);...|.modalst|
|00001860| 61 74 65 20 3d 20 6d 6f | 64 61 6c 64 69 61 6c 6f |ate = mo|daldialo|
|00001870| 67 3b 0d 09 6d 6f 64 61 | 6c 64 69 61 6c 6f 67 20 |g;..moda|ldialog |
|00001880| 3d 20 54 52 55 45 3b 0d | 09 53 65 74 43 75 72 73 |= TRUE;.|.SetCurs|
|00001890| 6f 72 28 26 61 72 72 6f | 77 29 3b 0d 09 73 68 6f |or(&arro|w);..sho|
|000018a0| 77 63 75 72 73 6f 72 28 | 29 3b 0d 09 53 65 74 50 |wcursor(|);..SetP|
|000018b0| 6f 72 74 28 68 65 6c 70 | 77 69 6e 64 29 3b 0d 0d |ort(help|wind);..|
|000018c0| 09 54 65 78 74 46 6f 6e | 74 28 66 6f 6e 74 29 3b |.TextFon|t(font);|
|000018d0| 0d 09 54 65 78 74 53 69 | 7a 65 28 66 6f 6e 74 73 |..TextSi|ze(fonts|
|000018e0| 69 7a 65 29 3b 0d 09 0d | 09 47 65 74 46 6f 6e 74 |ize);...|.GetFont|
|000018f0| 49 6e 66 6f 28 26 66 69 | 6e 66 6f 29 3b 0d 0d 09 |Info(&fi|nfo);...|
|00001900| 2f 2a 20 73 65 74 20 75 | 70 20 74 65 78 74 20 65 |/* set u|p text e|
|00001910| 64 69 74 20 72 65 63 6f | 72 64 20 2a 2f 0d 09 62 |dit reco|rd */..b|
|00001920| 6f 75 6e 64 73 2e 74 6f | 70 20 3d 20 36 3b 0d 09 |ounds.to|p = 6;..|
|00001930| 62 6f 75 6e 64 73 2e 6c | 65 66 74 20 3d 20 36 3b |bounds.l|eft = 6;|
|00001940| 0d 09 62 6f 75 6e 64 73 | 2e 62 6f 74 74 6f 6d 20 |..bounds|.bottom |
|00001950| 3d 20 74 68 65 50 6f 72 | 74 2d 3e 70 6f 72 74 52 |= thePor|t->portR|
|00001960| 65 63 74 2e 62 6f 74 74 | 6f 6d 3b 0d 09 62 6f 75 |ect.bott|om;..bou|
|00001970| 6e 64 73 2e 72 69 67 68 | 74 20 3d 20 74 68 65 50 |nds.righ|t = theP|
|00001980| 6f 72 74 2d 3e 70 6f 72 | 74 52 65 63 74 2e 72 69 |ort->por|tRect.ri|
|00001990| 67 68 74 20 2d 20 36 3b | 0d 09 68 65 6c 70 74 65 |ght - 6;|..helpte|
|000019a0| 68 61 6e 64 20 3d 20 54 | 45 4e 65 77 28 26 62 6f |hand = T|ENew(&bo|
|000019b0| 75 6e 64 73 2c 20 26 62 | 6f 75 6e 64 73 29 3b 0d |unds, &b|ounds);.|
|000019c0| 0d 09 28 2a 68 65 6c 70 | 74 65 68 61 6e 64 29 2d |..(*help|tehand)-|
|000019d0| 3e 66 6f 6e 74 41 73 63 | 65 6e 74 20 3d 20 66 69 |>fontAsc|ent = fi|
|000019e0| 6e 66 6f 2e 61 73 63 65 | 6e 74 20 2b 20 66 69 6e |nfo.asce|nt + fin|
|000019f0| 66 6f 2e 6c 65 61 64 69 | 6e 67 3b 0d 09 28 2a 68 |fo.leadi|ng;..(*h|
|00001a00| 65 6c 70 74 65 68 61 6e | 64 29 2d 3e 6c 69 6e 65 |elptehan|d)->line|
|00001a10| 48 65 69 67 68 74 20 3d | 20 28 2a 68 65 6c 70 74 |Height =| (*helpt|
|00001a20| 65 68 61 6e 64 29 2d 3e | 66 6f 6e 74 41 73 63 65 |ehand)->|fontAsce|
|00001a30| 6e 74 20 2b 20 66 69 6e | 66 6f 2e 64 65 73 63 65 |nt + fin|fo.desce|
|00001a40| 6e 74 3b 20 0d 0d 09 28 | 2a 68 65 6c 70 74 65 68 |nt; ...(|*helpteh|
|00001a50| 61 6e 64 29 2d 3e 74 78 | 46 6f 6e 74 20 3d 20 66 |and)->tx|Font = f|
|00001a60| 6f 6e 74 3b 0d 09 28 2a | 68 65 6c 70 74 65 68 61 |ont;..(*|helpteha|
|00001a70| 6e 64 29 2d 3e 74 78 53 | 69 7a 65 20 3d 20 66 6f |nd)->txS|ize = fo|
|00001a80| 6e 74 73 69 7a 65 3b 0d | 09 6e 75 6c 6c 72 65 63 |ntsize;.|.nullrec|
|00001a90| 74 2e 74 6f 70 20 3d 20 | 6e 75 6c 6c 72 65 63 74 |t.top = |nullrect|
|00001aa0| 2e 6c 65 66 74 20 3d 20 | 6e 75 6c 6c 72 65 63 74 |.left = |nullrect|
|00001ab0| 2e 62 6f 74 74 6f 6d 20 | 3d 20 6e 75 6c 6c 72 65 |.bottom |= nullre|
|00001ac0| 63 74 2e 72 69 67 68 74 | 20 3d 20 30 3b 0d 09 2f |ct.right| = 0;../|
|00001ad0| 2a 20 54 45 55 70 64 61 | 74 65 28 26 6e 75 6c 6c |* TEUpda|te(&null|
|00001ae0| 72 65 63 74 2c 20 68 65 | 6c 70 74 65 68 61 6e 64 |rect, he|lptehand|
|00001af0| 29 3b 0d 09 09 69 6e 63 | 6f 72 70 6f 72 61 74 65 |);...inc|orporate|
|00001b00| 20 74 68 65 20 69 6e 66 | 6f 20 2a 2f 0d 09 28 2a | the inf|o */..(*|
|00001b10| 68 65 6c 70 74 65 68 61 | 6e 64 29 2d 3e 76 69 65 |helpteha|nd)->vie|
|00001b20| 77 52 65 63 74 2e 62 6f | 74 74 6f 6d 20 3d 20 0d |wRect.bo|ttom = .|
|00001b30| 09 09 62 6f 75 6e 64 73 | 2e 74 6f 70 20 2b 0d 09 |..bounds|.top +..|
|00001b40| 09 28 28 74 68 65 50 6f | 72 74 2d 3e 70 6f 72 74 |.((thePo|rt->port|
|00001b50| 52 65 63 74 2e 62 6f 74 | 74 6f 6d 20 2d 20 62 6f |Rect.bot|tom - bo|
|00001b60| 75 6e 64 73 2e 74 6f 70 | 29 20 2f 20 28 2a 68 65 |unds.top|) / (*he|
|00001b70| 6c 70 74 65 68 61 6e 64 | 29 2d 3e 6c 69 6e 65 48 |lptehand|)->lineH|
|00001b80| 65 69 67 68 74 20 29 0d | 09 09 09 2a 20 28 2a 68 |eight ).|...* (*h|
|00001b90| 65 6c 70 74 65 68 61 6e | 64 29 2d 3e 6c 69 6e 65 |elptehan|d)->line|
|00001ba0| 48 65 69 67 68 74 3b 0d | 09 09 2f 2a 20 72 6f 75 |Height;.|../* rou|
|00001bb0| 6e 64 20 68 65 69 67 68 | 74 20 6f 66 20 76 69 65 |nd heigh|t of vie|
|00001bc0| 77 20 72 65 63 74 20 74 | 6f 20 65 76 65 6e 20 62 |w rect t|o even b|
|00001bd0| 69 74 20 6d 75 6c 74 69 | 70 6c 65 20 6f 66 20 66 |it multi|ple of f|
|00001be0| 6f 6e 74 20 73 69 7a 65 | 20 2a 2f 0d 0d 09 2f 2a |ont size| */.../*|
|00001bf0| 20 69 6e 73 65 72 74 20 | 74 68 65 20 74 65 78 74 | insert |the text|
|00001c00| 20 2a 2f 0d 09 54 45 53 | 65 74 53 65 6c 65 63 74 | */..TES|etSelect|
|00001c10| 28 20 28 6c 6f 6e 67 29 | 20 30 2c 20 28 6c 6f 6e |( (long)| 0, (lon|
|00001c20| 67 29 20 28 2a 68 65 6c | 70 74 65 68 61 6e 64 29 |g) (*hel|ptehand)|
|00001c30| 2d 3e 74 65 4c 65 6e 67 | 74 68 2c 20 68 65 6c 70 |->teLeng|th, help|
|00001c40| 74 65 68 61 6e 64 29 3b | 0d 09 54 45 49 6e 73 65 |tehand);|..TEInse|
|00001c50| 72 74 28 74 68 65 74 65 | 78 74 2c 20 28 6c 6f 6e |rt(thete|xt, (lon|
|00001c60| 67 29 20 6c 65 6e 67 74 | 68 2c 20 68 65 6c 70 74 |g) lengt|h, helpt|
|00001c70| 65 68 61 6e 64 29 3b 0d | 0d 09 69 66 20 28 77 61 |ehand);.|..if (wa|
|00001c80| 69 74 66 6f 72 20 3d 3d | 20 2d 31 29 20 7b 0d 09 |itfor ==| -1) {..|
|00001c90| 09 2f 2a 20 65 78 69 74 | 20 69 6d 6d 65 64 69 61 |./* exit| immedia|
|00001ca0| 74 65 6c 79 2c 20 61 70 | 70 20 6d 75 73 74 20 64 |tely, ap|p must d|
|00001cb0| 6f 20 63 6c 65 61 6e 75 | 70 20 69 74 73 65 6c 66 |o cleanu|p itself|
|00001cc0| 20 62 79 20 63 61 6c 6c | 69 6e 67 20 66 69 6c 6c | by call|ing fill|
|00001cd0| 77 69 6e 64 63 6c 6f 73 | 65 28 29 20 2a 2f 0d 09 |windclos|e() */..|
|00001ce0| 09 53 65 74 50 6f 72 74 | 28 6f 68 65 6c 70 70 6f |.SetPort|(ohelppo|
|00001cf0| 72 74 29 3b 0d 09 09 66 | 69 6c 6c 74 69 6d 65 6f |rt);...f|illtimeo|
|00001d00| 75 74 20 3d 20 63 74 69 | 63 6b 73 20 2b 20 35 30 |ut = cti|cks + 50|
|00001d10| 30 3b 09 2f 2a 4b 53 2a | 2f 0d 09 09 6d 6f 64 61 |0;./*KS*|/...moda|
|00001d20| 6c 64 69 61 6c 6f 67 20 | 3d 20 6d 6f 64 61 6c 73 |ldialog |= modals|
|00001d30| 74 61 74 65 3b 0d 09 09 | 72 65 74 75 72 6e 28 30 |tate;...|return(0|
|00001d40| 29 3b 0d 09 7d 0d 0d 09 | 66 69 6c 6c 74 69 6d 65 |);..}...|filltime|
|00001d50| 6f 75 74 20 3d 20 63 74 | 69 63 6b 73 20 2b 20 77 |out = ct|icks + w|
|00001d60| 61 69 74 66 6f 72 3b 09 | 2f 2a 4b 53 2a 2f 0d 0d |aitfor;.|/*KS*/..|
|00001d70| 09 2f 2a 20 77 61 69 74 | 20 74 69 6c 6c 20 61 20 |./* wait| till a |
|00001d80| 74 69 6d 65 6f 75 74 20 | 6f 72 20 6d 6f 75 73 65 |timeout |or mouse|
|00001d90| 44 6f 77 6e 20 65 76 65 | 6e 74 20 6f 63 63 75 72 |Down eve|nt occur|
|00001da0| 73 20 74 6f 20 65 78 69 | 74 2c 20 75 6e 6c 65 73 |s to exi|t, unles|
|00001db0| 73 20 61 20 6b 65 79 20 | 69 73 20 68 69 74 20 2a |s a key |is hit *|
|00001dc0| 2f 0d 09 77 68 69 6c 65 | 20 28 54 52 55 45 29 20 |/..while| (TRUE) |
|00001dd0| 7b 0d 09 09 45 76 65 6e | 74 52 65 63 6f 72 64 20 |{...Even|tRecord |
|00001de0| 61 6e 65 76 65 6e 74 3b | 0d 0d 09 09 69 66 20 28 |anevent;|....if (|
|00001df0| 77 61 69 74 66 6f 72 29 | 20 7b 0d 09 09 09 2f 2a |waitfor)| {..../*|
|00001e00| 20 69 66 20 61 20 6e 6f | 6e 7a 65 72 6f 20 74 69 | if a no|nzero ti|
|00001e10| 6d 65 6f 75 74 20 68 61 | 73 20 62 65 65 6e 20 67 |meout ha|s been g|
|00001e20| 69 76 65 6e 2c 20 63 68 | 65 63 6b 20 74 68 65 20 |iven, ch|eck the |
|00001e30| 74 69 6d 65 20 2a 2f 0d | 09 09 09 69 66 20 28 63 |time */.|...if (c|
|00001e40| 74 69 63 6b 73 20 3e 20 | 66 69 6c 6c 74 69 6d 65 |ticks > |filltime|
|00001e50| 6f 75 74 29 0d 09 09 09 | 09 62 72 65 61 6b 3b 0d |out)....|.break;.|
|00001e60| 09 09 7d 0d 09 09 69 66 | 20 28 21 47 65 74 4e 65 |..}...if| (!GetNe|
|00001e70| 78 74 45 76 65 6e 74 28 | 6d 44 6f 77 6e 4d 61 73 |xtEvent(|mDownMas|
|00001e80| 6b 2c 20 26 61 6e 65 76 | 65 6e 74 29 29 20 7b 0d |k, &anev|ent)) {.|
|00001e90| 09 09 09 2f 2a 20 77 61 | 69 74 20 66 6f 72 20 61 |.../* wa|it for a|
|00001ea0| 20 6d 6f 75 73 65 64 6f | 77 6e 3b 20 64 6f 6e 27 | mousedo|wn; don'|
|00001eb0| 74 20 74 61 6b 65 20 6b | 65 79 73 74 72 6f 6b 65 |t take k|eystroke|
|00001ec0| 73 20 6f 66 66 20 74 68 | 65 20 71 75 65 75 65 20 |s off th|e queue |
|00001ed0| 2a 2f 0d 09 09 09 53 79 | 73 74 65 6d 54 61 73 6b |*/....Sy|stemTask|
|00001ee0| 28 29 3b 09 09 09 09 2f | 2a 20 6b 65 65 70 20 74 |();..../|* keep t|
|00001ef0| 68 69 73 20 69 66 2f 75 | 6e 74 69 6c 20 77 65 20 |his if/u|ntil we |
|00001f00| 75 73 65 20 57 61 69 74 | 4e 65 78 74 45 76 65 6e |use Wait|NextEven|
|00001f10| 74 20 2a 2f 0d 09 09 09 | 69 66 20 28 74 6b 5f 63 |t */....|if (tk_c|
|00001f20| 75 72 20 21 3d 20 4e 55 | 4c 4c 29 20 7b 0d 09 09 |ur != NU|LL) {...|
|00001f30| 09 09 2f 2a 20 69 66 20 | 74 61 73 6b 69 6e 67 20 |../* if |tasking |
|00001f40| 69 73 20 6f 6e 2c 20 64 | 6f 20 61 20 79 69 65 6c |is on, d|o a yiel|
|00001f50| 64 20 74 6f 20 61 76 6f | 69 64 20 74 69 6d 65 6f |d to avo|id timeo|
|00001f60| 75 74 20 2a 2f 0d 09 09 | 09 09 62 6b 72 64 5f 73 |ut */...|..bkrd_s|
|00001f70| 65 72 76 69 63 65 28 29 | 3b 0d 09 09 09 7d 0d 09 |ervice()|;....}..|
|00001f80| 09 09 63 6f 6e 74 69 6e | 75 65 3b 09 09 2f 2a 20 |..contin|ue;../* |
|00001f90| 4b 53 20 2a 2f 0d 09 09 | 7d 0d 09 09 53 65 74 50 |KS */...|}...SetP|
|00001fa0| 6f 72 74 28 68 65 6c 70 | 77 69 6e 64 29 3b 0d 09 |ort(help|wind);..|
|00001fb0| 09 2f 2a 20 64 6f 20 70 | 61 67 69 6e 67 20 69 66 |./* do p|aging if|
|00001fc0| 20 74 65 78 74 20 6f 66 | 66 20 62 6f 74 74 6f 6d | text of|f bottom|
|00001fd0| 20 2a 2f 0d 09 09 69 66 | 20 28 20 28 28 2a 68 65 | */...if| ( ((*he|
|00001fe0| 6c 70 74 65 68 61 6e 64 | 29 2d 3e 6c 69 6e 65 48 |lptehand|)->lineH|
|00001ff0| 65 69 67 68 74 20 2a 20 | 28 2a 68 65 6c 70 74 65 |eight * |(*helpte|
|00002000| 68 61 6e 64 29 2d 3e 6e | 4c 69 6e 65 73 20 2b 20 |hand)->n|Lines + |
|00002010| 28 2a 68 65 6c 70 74 65 | 68 61 6e 64 29 2d 3e 64 |(*helpte|hand)->d|
|00002020| 65 73 74 52 65 63 74 2e | 74 6f 70 20 29 0d 09 09 |estRect.|top )...|
|00002030| 09 09 3e 20 28 2a 68 65 | 6c 70 74 65 68 61 6e 64 |..> (*he|lptehand|
|00002040| 29 2d 3e 76 69 65 77 52 | 65 63 74 2e 62 6f 74 74 |)->viewR|ect.bott|
|00002050| 6f 6d 20 29 20 7b 0d 09 | 09 09 09 2f 2a 20 64 6f |om ) {..|.../* do|
|00002060| 20 61 20 73 63 72 6f 6c | 6c 20 77 68 65 6e 20 62 | a scrol|l when b|
|00002070| 6f 74 74 6f 6d 20 6f 66 | 20 74 65 78 74 20 62 65 |ottom of| text be|
|00002080| 6c 6f 77 20 62 6f 74 74 | 6f 6d 20 6f 66 20 77 69 |low bott|om of wi|
|00002090| 6e 64 6f 77 20 2a 2f 0d | 09 09 09 54 45 53 63 72 |ndow */.|...TEScr|
|000020a0| 6f 6c 6c 28 30 2c 20 2d | 20 28 28 2a 68 65 6c 70 |oll(0, -| ((*help|
|000020b0| 74 65 68 61 6e 64 29 2d | 3e 76 69 65 77 52 65 63 |tehand)-|>viewRec|
|000020c0| 74 2e 62 6f 74 74 6f 6d | 20 2d 20 28 2a 68 65 6c |t.bottom| - (*hel|
|000020d0| 70 74 65 68 61 6e 64 29 | 2d 3e 76 69 65 77 52 65 |ptehand)|->viewRe|
|000020e0| 63 74 2e 74 6f 70 29 2c | 20 68 65 6c 70 74 65 68 |ct.top),| helpteh|
|000020f0| 61 6e 64 29 3b 0d 09 09 | 09 63 6f 6e 74 69 6e 75 |and);...|.continu|
|00002100| 65 3b 0d 09 09 7d 0d 09 | 09 65 6c 73 65 20 0d 09 |e;...}..|.else ..|
|00002110| 09 09 62 72 65 61 6b 3b | 0d 09 7d 0d 0d 09 2f 2a |..break;|..}.../*|
|00002120| 20 72 65 6c 65 61 73 65 | 20 2a 2f 0d 09 54 45 44 | release| */..TED|
|00002130| 69 73 70 6f 73 65 28 68 | 65 6c 70 74 65 68 61 6e |ispose(h|elptehan|
|00002140| 64 29 3b 0d 09 44 69 73 | 70 6f 73 65 57 69 6e 64 |d);..Dis|poseWind|
|00002150| 6f 77 28 68 65 6c 70 77 | 69 6e 64 29 3b 0d 09 68 |ow(helpw|ind);..h|
|00002160| 65 6c 70 77 69 6e 64 20 | 3d 20 4e 55 4c 4c 3b 0d |elpwind |= NULL;.|
|00002170| 09 6d 6f 64 61 6c 64 69 | 61 6c 6f 67 20 3d 20 6d |.modaldi|alog = m|
|00002180| 6f 64 61 6c 73 74 61 74 | 65 3b 0d 7d 0d 0d 0d 2f |odalstat|e;.}.../|
|00002190| 2a 20 64 69 73 70 6f 73 | 65 20 6f 66 20 74 68 65 |* dispos|e of the|
|000021a0| 20 77 69 6e 64 6f 77 20 | 63 72 65 61 74 65 64 20 | window |created |
|000021b0| 62 79 20 66 69 6c 6c 77 | 69 6e 64 20 2a 2f 0d 0d |by fillw|ind */..|
|000021c0| 66 69 6c 6c 77 69 6e 64 | 63 6c 6f 73 65 28 29 0d |fillwind|close().|
|000021d0| 7b 0d 09 2f 2a 20 72 65 | 6c 65 61 73 65 20 2a 2f |{../* re|lease */|
|000021e0| 0d 09 69 66 20 28 68 65 | 6c 70 77 69 6e 64 20 21 |..if (he|lpwind !|
|000021f0| 3d 20 4e 55 4c 4c 29 20 | 7b 0d 09 09 77 68 69 6c |= NULL) |{...whil|
|00002200| 65 20 28 54 52 55 45 29 | 20 7b 0d 09 09 09 2f 2a |e (TRUE)| {..../*|
|00002210| 20 67 75 61 72 61 6e 74 | 65 65 20 74 68 65 20 63 | guarant|ee the c|
|00002220| 6f 70 79 72 69 67 68 74 | 20 6e 6f 74 69 63 65 20 |opyright| notice |
|00002230| 73 74 61 79 73 20 75 70 | 20 6c 6f 6e 67 20 65 6e |stays up| long en|
|00002240| 6f 75 67 68 20 74 6f 20 | 62 65 20 73 65 65 6e 20 |ough to |be seen |
|00002250| 2a 2f 0d 09 09 09 69 66 | 20 28 63 74 69 63 6b 73 |*/....if| (cticks|
|00002260| 20 3e 20 66 69 6c 6c 74 | 69 6d 65 6f 75 74 29 0d | > fillt|imeout).|
|00002270| 09 09 09 09 62 72 65 61 | 6b 3b 0d 09 09 7d 0d 09 |....brea|k;...}..|
|00002280| 09 54 45 44 69 73 70 6f | 73 65 28 68 65 6c 70 74 |.TEDispo|se(helpt|
|00002290| 65 68 61 6e 64 29 3b 0d | 09 09 44 69 73 70 6f 73 |ehand);.|..Dispos|
|000022a0| 65 57 69 6e 64 6f 77 28 | 68 65 6c 70 77 69 6e 64 |eWindow(|helpwind|
|000022b0| 29 3b 0d 09 09 68 65 6c | 70 77 69 6e 64 20 3d 20 |);...hel|pwind = |
|000022c0| 4e 55 4c 4c 3b 0d 09 7d | 0d 7d 0d 0d 0d 2f 2a 20 |NULL;..}|.}.../* |
|000022d0| 64 69 73 70 6c 61 79 20 | 61 20 63 6f 70 79 72 69 |display |a copyri|
|000022e0| 67 68 74 20 6e 6f 74 69 | 63 65 3b 20 61 70 70 20 |ght noti|ce; app |
|000022f0| 6d 75 73 74 20 63 6c 65 | 61 6e 20 75 70 20 77 2f |must cle|an up w/|
|00002300| 20 66 69 6c 6c 77 69 6e | 64 63 6c 6f 73 65 28 29 | fillwin|dclose()|
|00002310| 20 2a 2f 0d 0d 63 6f 70 | 79 6e 6f 74 69 63 65 28 | */..cop|ynotice(|
|00002320| 29 0d 7b 0d 09 65 78 74 | 65 72 6e 20 63 68 61 72 |).{..ext|ern char|
|00002330| 20 63 6f 70 79 72 69 67 | 68 74 5b 5d 3b 09 2f 2a | copyrig|ht[];./*|
|00002340| 20 69 6e 20 61 70 70 6c | 2f 63 6f 70 79 2e 63 20 | in appl|/copy.c |
|00002350| 2a 2f 0d 09 45 76 65 6e | 74 52 65 63 6f 72 64 20 |*/..Even|tRecord |
|00002360| 6d 79 45 76 65 6e 74 3b | 0d 0d 09 2f 2a 20 65 76 |myEvent;|.../* ev|
|00002370| 65 6e 74 61 76 61 69 6c | 20 77 69 6c 6c 20 70 75 |entavail| will pu|
|00002380| 74 20 74 68 65 73 65 20 | 62 61 63 6b 20 6f 6e 20 |t these |back on |
|00002390| 74 68 65 20 71 75 65 75 | 65 2c 20 62 75 74 20 6e |the queu|e, but n|
|000023a0| 6f 74 20 61 6e 79 20 65 | 76 65 6e 74 21 20 2a 2f |ot any e|vent! */|
|000023b0| 0d 09 45 76 65 6e 74 41 | 76 61 69 6c 28 6b 65 79 |..EventA|vail(key|
|000023c0| 44 6f 77 6e 4d 61 73 6b | 2c 20 26 6d 79 45 76 65 |DownMask|, &myEve|
|000023d0| 6e 74 29 3b 0d 09 45 76 | 65 6e 74 41 76 61 69 6c |nt);..Ev|entAvail|
|000023e0| 28 6b 65 79 44 6f 77 6e | 4d 61 73 6b 2c 20 26 6d |(keyDown|Mask, &m|
|000023f0| 79 45 76 65 6e 74 29 3b | 0d 09 45 76 65 6e 74 41 |yEvent);|..EventA|
|00002400| 76 61 69 6c 28 6b 65 79 | 44 6f 77 6e 4d 61 73 6b |vail(key|DownMask|
|00002410| 2c 20 26 6d 79 45 76 65 | 6e 74 29 3b 0d 09 09 2f |, &myEve|nt);.../|
|00002420| 2a 20 74 68 65 73 65 20 | 63 61 6c 6c 73 20 77 69 |* these |calls wi|
|00002430| 6c 6c 20 70 72 6f 6d 70 | 74 20 74 68 65 20 4d 75 |ll promp|t the Mu|
|00002440| 6c 74 69 46 69 6e 64 65 | 72 20 74 6f 20 64 69 73 |ltiFinde|r to dis|
|00002450| 70 6c 61 79 20 6f 75 72 | 20 73 74 61 72 74 75 70 |play our| startup|
|00002460| 20 73 63 72 65 65 6e 20 | 2a 2f 0d 09 66 69 6c 6c | screen |*/..fill|
|00002470| 77 69 6e 64 6f 77 28 43 | 4f 50 59 57 49 4e 44 4f |window(C|OPYWINDO|
|00002480| 57 2c 20 63 6f 70 79 72 | 69 67 68 74 2c 20 28 6c |W, copyr|ight, (l|
|00002490| 6f 6e 67 29 20 73 74 72 | 6c 65 6e 28 63 6f 70 79 |ong) str|len(copy|
|000024a0| 72 69 67 68 74 29 2c 20 | 67 65 6e 65 76 61 2c 20 |right), |geneva, |
|000024b0| 31 32 2c 20 28 6c 6f 6e | 67 29 20 2d 31 29 3b 0d |12, (lon|g) -1);.|
|000024c0| 7d 0d 0d 0d 2f 2a 20 64 | 6f 20 64 69 61 6c 6f 67 |}.../* d|o dialog|
|000024d0| 20 74 6f 20 67 65 74 20 | 63 6f 6e 6e 65 63 74 69 | to get |connecti|
|000024e0| 6f 6e 20 74 79 70 65 2c | 20 74 65 72 6d 69 6e 61 |on type,| termina|
|000024f0| 6c 20 74 79 70 65 2c 20 | 26 20 49 42 4d 20 37 31 |l type, |& IBM 71|
|00002500| 37 31 20 6b 65 79 0d 09 | 6d 61 70 70 69 6e 67 20 |71 key..|mapping |
|00002510| 2a 2f 0d 0d 23 64 65 66 | 69 6e 65 20 4e 4d 5f 54 |*/..#def|ine NM_T|
|00002520| 49 54 4c 45 09 33 09 09 | 2f 2a 20 74 69 74 6c 65 |ITLE.3..|/* title|
|00002530| 20 6f 66 20 64 69 61 6c | 6f 67 20 62 6f 78 2c 20 | of dial|og box, |
|00002540| 6e 61 6d 65 20 61 6e 64 | 20 76 65 72 73 69 6f 6e |name and| version|
|00002550| 20 2a 2f 0d 0d 2f 2a 20 | 63 6f 6e 6e 65 63 74 69 | */../* |connecti|
|00002560| 6f 6e 20 74 79 70 65 73 | 20 2a 2f 0d 23 64 65 66 |on types| */.#def|
|00002570| 69 6e 65 20 4e 4d 5f 43 | 4f 4e 4e 09 09 35 09 09 |ine NM_C|ONN..5..|
|00002580| 2f 2a 20 63 6f 6e 6e 74 | 79 70 65 20 3d 20 74 68 |/* connt|ype = th|
|00002590| 65 20 43 6f 6e 6e 65 63 | 74 69 6f 6e 20 4d 61 6e |e Connec|tion Man|
|000025a0| 61 67 65 72 20 2a 2f 0d | 23 64 65 66 69 6e 65 20 |ager */.|#define |
|000025b0| 4e 4d 5f 53 45 52 44 41 | 09 36 09 09 2f 2a 20 20 |NM_SERDA|.6../* |
|000025c0| 3d 20 73 65 72 69 61 6c | 20 70 6f 72 74 20 61 20 |= serial| port a |
|000025d0| 2a 2f 0d 23 64 65 66 69 | 6e 65 20 4e 4d 5f 53 45 |*/.#defi|ne NM_SE|
|000025e0| 52 44 42 09 37 09 09 2f | 2a 20 20 3d 20 73 65 72 |RDB.7../|* = ser|
|000025f0| 69 61 6c 20 70 6f 72 74 | 20 62 20 2a 2f 0d 23 64 |ial port| b */.#d|
|00002600| 65 66 69 6e 65 20 4e 4d | 5f 54 43 50 09 09 38 09 |efine NM|_TCP..8.|
|00002610| 09 2f 2a 20 20 3d 20 54 | 43 50 20 2a 2f 0d 23 64 |./* = T|CP */.#d|
|00002620| 65 66 69 6e 65 20 4e 4d | 5f 48 4f 53 54 41 44 44 |efine NM|_HOSTADD|
|00002630| 52 54 49 54 09 39 09 09 | 2f 2a 20 20 3d 20 54 43 |RTIT.9..|/* = TC|
|00002640| 50 20 2a 2f 0d 23 64 65 | 66 69 6e 65 20 4e 4d 5f |P */.#de|fine NM_|
|00002650| 43 55 54 43 50 09 31 37 | 09 09 2f 2a 20 20 3d 20 |CUTCP.17|../* = |
|00002660| 43 6f 72 6e 65 6c 6c 27 | 73 20 54 43 50 20 2a 2f |Cornell'|s TCP */|
|00002670| 0d 0d 23 64 65 66 69 6e | 65 20 4e 4d 5f 48 4f 53 |..#defin|e NM_HOS|
|00002680| 54 4e 41 4d 45 09 31 31 | 09 09 2f 2a 20 74 68 65 |TNAME.11|../* the|
|00002690| 20 68 6f 73 74 6e 61 6d | 65 20 66 69 65 6c 64 20 | hostnam|e field |
|000026a0| 2a 2f 0d 23 64 65 66 69 | 6e 65 20 4e 4d 5f 48 4f |*/.#defi|ne NM_HO|
|000026b0| 53 54 41 44 44 52 09 31 | 32 09 09 2f 2a 20 74 68 |STADDR.1|2../* th|
|000026c0| 65 20 68 6f 73 74 20 61 | 64 64 72 65 73 73 20 66 |e host a|ddress f|
|000026d0| 69 65 6c 64 20 2a 2f 0d | 23 64 65 66 69 6e 65 20 |ield */.|#define |
|000026e0| 4e 4d 5f 49 42 4d 4b 45 | 59 09 31 36 09 09 2f 2a |NM_IBMKE|Y.16../*|
|000026f0| 20 63 68 65 63 6b 20 62 | 6f 78 20 66 6f 72 20 73 | check b|ox for s|
|00002700| 65 72 69 61 6c 20 49 42 | 4d 20 6d 6f 64 65 20 2a |erial IB|M mode *|
|00002710| 2f 0d 23 64 65 66 69 6e | 65 20 4e 4d 5f 48 45 4c |/.#defin|e NM_HEL|
|00002720| 50 42 55 54 09 31 38 09 | 09 2f 2a 20 68 65 6c 70 |PBUT.18.|./* help|
|00002730| 20 62 75 74 74 6f 6e 20 | 2a 2f 0d 0d 2f 2a 20 74 | button |*/../* t|
|00002740| 65 72 6d 69 6e 61 6c 20 | 74 79 70 65 73 20 2a 2f |erminal |types */|
|00002750| 0d 23 64 65 66 69 6e 65 | 20 4e 4d 5f 45 4d 41 55 |.#define| NM_EMAU|
|00002760| 54 4f 4d 41 54 49 43 09 | 31 39 09 2f 2a 20 74 72 |TOMATIC.|19./* tr|
|00002770| 79 20 61 6c 6c 20 6f 66 | 20 74 68 65 6d 2d 2d 54 |y all of| them--T|
|00002780| 65 6c 6e 65 74 20 6e 65 | 67 6f 74 69 61 74 69 6f |elnet ne|gotiatio|
|00002790| 6e 2c 20 73 65 72 69 61 | 6c 20 76 74 31 30 30 20 |n, seria|l vt100 |
|000027a0| 2a 2f 0d 23 64 65 66 69 | 6e 65 20 4e 4d 5f 56 54 |*/.#defi|ne NM_VT|
|000027b0| 31 30 30 09 32 30 0d 23 | 64 65 66 69 6e 65 20 4e |100.20.#|define N|
|000027c0| 4d 5f 33 32 37 38 09 09 | 32 31 0d 23 64 65 66 69 |M_3278..|21.#defi|
|000027d0| 6e 65 20 4e 4d 5f 48 31 | 39 09 09 32 32 0d 23 64 |ne NM_H1|9..22.#d|
|000027e0| 65 66 69 6e 65 20 4e 4d | 5f 56 54 31 30 32 09 32 |efine NM|_VT102.2|
|000027f0| 33 0d 23 64 65 66 69 6e | 65 20 4e 4d 5f 56 54 32 |3.#defin|e NM_VT2|
|00002800| 32 30 09 32 34 09 09 2f | 2a 20 75 6e 75 73 65 64 |20.24../|* unused|
|00002810| 20 2a 2f 0d 0d 0d 2f 2a | 20 77 65 20 6e 65 65 64 | */.../*| we need|
|00002820| 20 74 6f 20 67 65 74 20 | 69 6e 73 69 64 65 20 74 | to get |inside t|
|00002830| 68 65 20 4d 6f 64 61 6c | 44 69 61 6c 6f 67 20 65 |he Modal|Dialog e|
|00002840| 76 65 6e 74 20 6c 6f 6f | 70 20 74 6f 20 67 75 61 |vent loo|p to gua|
|00002850| 72 61 6e 74 65 65 20 63 | 79 63 6c 65 73 20 66 6f |rantee c|ycles fo|
|00002860| 72 20 74 61 73 6b 73 2d | 2d 68 65 6e 63 65 2c 20 |r tasks-|-hence, |
|00002870| 2a 2f 0d 0d 52 65 63 74 | 20 6c 69 73 74 72 65 63 |*/..Rect| listrec|
|00002880| 74 3b 09 09 09 09 2f 2a | 20 74 68 65 20 72 65 63 |t;..../*| the rec|
|00002890| 74 61 6e 67 6c 65 20 75 | 73 65 72 20 69 74 65 6d |tangle u|ser item|
|000028a0| 20 69 6e 20 77 68 69 63 | 68 20 6c 69 73 74 20 61 | in whic|h list a|
|000028b0| 70 70 65 61 72 73 20 2a | 2f 0d 0d 23 69 66 64 65 |ppears *|/..#ifde|
|000028c0| 66 20 54 43 50 53 45 4c | 45 43 54 0d 73 68 6f 72 |f TCPSEL|ECT.shor|
|000028d0| 74 20 69 70 61 64 64 72 | 76 69 73 20 3d 20 54 52 |t ipaddr|vis = TR|
|000028e0| 55 45 3b 09 09 09 2f 2a | 20 74 68 65 20 49 50 20 |UE;.../*| the IP |
|000028f0| 61 64 64 72 65 73 73 20 | 68 61 73 20 6e 6f 74 20 |address |has not |
|00002900| 62 65 65 6e 20 68 69 64 | 64 65 6e 20 2a 2f 0d 23 |been hid|den */.#|
|00002910| 65 6e 64 69 66 0d 0d 70 | 61 73 63 61 6c 20 42 6f |endif..p|ascal Bo|
|00002920| 6f 6c 65 61 6e 0d 6e 6d | 77 69 6e 64 6f 77 66 69 |olean.nm|windowfi|
|00002930| 6c 74 65 72 28 64 70 74 | 72 2c 20 64 65 76 74 2c |lter(dpt|r, devt,|
|00002940| 20 69 74 65 6d 29 0d 44 | 69 61 6c 6f 67 50 74 72 | item).D|ialogPtr|
|00002950| 20 64 70 74 72 3b 0d 45 | 76 65 6e 74 52 65 63 6f | dptr;.E|ventReco|
|00002960| 72 64 20 2a 20 64 65 76 | 74 3b 0d 69 6e 74 20 2a |rd * dev|t;.int *|
|00002970| 20 69 74 65 6d 3b 0d 7b | 0d 09 75 6e 69 6f 6e 20 | item;.{|..union |
|00002980| 7b 0d 09 09 6c 6f 6e 67 | 20 6c 3b 0d 09 09 50 6f |{...long| l;...Po|
|00002990| 69 6e 74 20 70 3b 0d 09 | 7d 20 70 72 65 76 63 65 |int p;..|} prevce|
|000029a0| 6c 6c 3b 0d 0d 09 62 6b | 72 64 5f 73 65 72 76 69 |ll;...bk|rd_servi|
|000029b0| 63 65 28 29 3b 0d 09 69 | 66 20 28 64 65 76 74 2d |ce();..i|f (devt-|
|000029c0| 3e 77 68 61 74 20 3d 3d | 20 6b 65 79 44 6f 77 6e |>what ==| keyDown|
|000029d0| 29 20 7b 0d 09 09 69 66 | 20 28 28 64 65 76 74 2d |) {...if| ((devt-|
|000029e0| 3e 6d 65 73 73 61 67 65 | 20 26 20 30 78 66 66 29 |>message| & 0xff)|
|000029f0| 20 3d 3d 20 43 52 20 7c | 7c 20 28 64 65 76 74 2d | == CR ||| (devt-|
|00002a00| 3e 6d 65 73 73 61 67 65 | 20 26 20 30 78 66 66 29 |>message| & 0xff)|
|00002a10| 20 3d 3d 20 45 54 58 29 | 20 7b 0d 09 09 09 64 65 | == ETX)| {....de|
|00002a20| 76 74 2d 3e 77 68 61 74 | 20 3d 20 6e 75 6c 6c 45 |vt->what| = nullE|
|00002a30| 76 65 6e 74 3b 09 2f 2a | 20 69 67 6e 6f 72 65 20 |vent;./*| ignore |
|00002a40| 74 68 65 20 6b 65 79 20 | 2a 2f 0d 09 09 09 2a 69 |the key |*/....*i|
|00002a50| 74 65 6d 20 3d 20 4f 4b | 42 3b 09 2f 2a 20 64 65 |tem = OK|B;./* de|
|00002a60| 66 61 75 6c 74 20 64 6f | 77 6e 20 2a 2f 0d 09 09 |fault do|wn */...|
|00002a70| 09 72 65 74 75 72 6e 28 | 28 42 6f 6f 6c 65 61 6e |.return(|(Boolean|
|00002a80| 29 20 54 52 55 45 29 3b | 0d 09 09 7d 0d 09 09 69 |) TRUE);|...}...i|
|00002a90| 66 20 28 64 65 76 74 2d | 3e 6d 6f 64 69 66 69 65 |f (devt-|>modifie|
|00002aa0| 72 73 20 26 20 63 6d 64 | 4b 65 79 29 20 7b 0d 09 |rs & cmd|Key) {..|
|00002ab0| 09 09 2f 2a 20 64 6f 20 | 43 61 6e 63 65 6c 20 2a |../* do |Cancel *|
|00002ac0| 2f 0d 09 09 09 63 68 61 | 72 20 74 68 65 63 68 61 |/....cha|r thecha|
|00002ad0| 72 3b 0d 09 09 09 0d 09 | 09 09 74 68 65 63 68 61 |r;......|..thecha|
|00002ae0| 72 20 3d 20 64 65 76 74 | 2d 3e 6d 65 73 73 61 67 |r = devt|->messag|
|00002af0| 65 20 26 20 30 78 66 66 | 3b 0d 09 09 09 73 77 69 |e & 0xff|;....swi|
|00002b00| 74 63 68 20 28 74 68 65 | 63 68 61 72 29 20 7b 0d |tch (the|char) {.|
|00002b10| 09 09 09 09 63 61 73 65 | 20 27 78 27 3a 20 7b 0d |....case| 'x': {.|
|00002b20| 09 09 09 09 09 44 6c 67 | 43 75 74 28 64 70 74 72 |.....Dlg|Cut(dptr|
|00002b30| 29 3b 0d 09 09 09 09 09 | 2a 69 74 65 6d 20 3d 20 |);......|*item = |
|00002b40| 30 3b 09 0d 09 09 09 09 | 09 72 65 74 75 72 6e 28 |0;......|.return(|
|00002b50| 54 52 55 45 29 3b 0d 09 | 09 09 09 7d 0d 09 09 09 |TRUE);..|...}....|
|00002b60| 09 63 61 73 65 20 27 63 | 27 3a 20 7b 0d 09 09 09 |.case 'c|': {....|
|00002b70| 09 09 44 6c 67 43 6f 70 | 79 28 64 70 74 72 29 3b |..DlgCop|y(dptr);|
|00002b80| 0d 09 09 09 09 09 2a 69 | 74 65 6d 20 3d 20 30 3b |......*i|tem = 0;|
|00002b90| 09 0d 09 09 09 09 09 72 | 65 74 75 72 6e 28 54 52 |.......r|eturn(TR|
|00002ba0| 55 45 29 3b 0d 09 09 09 | 09 7d 0d 09 09 09 09 63 |UE);....|.}.....c|
|00002bb0| 61 73 65 20 27 76 27 3a | 20 7b 0d 09 09 09 09 09 |ase 'v':| {......|
|00002bc0| 44 6c 67 50 61 73 74 65 | 28 64 70 74 72 29 3b 0d |DlgPaste|(dptr);.|
|00002bd0| 09 09 09 09 09 2a 69 74 | 65 6d 20 3d 20 30 3b 09 |.....*it|em = 0;.|
|00002be0| 0d 09 09 09 09 09 72 65 | 74 75 72 6e 28 54 52 55 |......re|turn(TRU|
|00002bf0| 45 29 3b 0d 09 09 09 09 | 7d 0d 09 09 09 09 63 61 |E);.....|}.....ca|
|00002c00| 73 65 20 27 2e 27 3a 20 | 7b 0d 09 09 09 09 09 2f |se '.': |{....../|
|00002c10| 2a 20 43 6f 6d 6d 61 6e | 64 2d 2e 20 69 73 20 61 |* Comman|d-. is a|
|00002c20| 20 43 61 6e 63 65 6c 20 | 2a 2f 0d 09 09 09 09 09 | Cancel |*/......|
|00002c30| 2a 69 74 65 6d 20 3d 20 | 43 41 4e 42 3b 09 0d 09 |*item = |CANB;...|
|00002c40| 09 09 09 09 72 65 74 75 | 72 6e 28 54 52 55 45 29 |....retu|rn(TRUE)|
|00002c50| 3b 0d 09 09 09 09 7d 0d | 09 09 09 7d 0d 09 09 7d |;.....}.|...}...}|
|00002c60| 0d 23 69 66 64 65 66 20 | 54 43 50 53 45 4c 45 43 |.#ifdef |TCPSELEC|
|00002c70| 54 0d 09 2f 2a 20 69 74 | 27 73 20 61 20 62 69 74 |T../* it|'s a bit|
|00002c80| 63 68 20 74 6f 20 6d 61 | 6b 65 20 74 63 70 20 73 |ch to ma|ke tcp s|
|00002c90| 65 6c 65 63 74 69 6f 6e | 73 20 74 75 72 6e 20 6f |election|s turn o|
|00002ca0| 6e 20 61 6e 64 20 6f 66 | 66 20 69 6e 74 65 6c 6c |n and of|f intell|
|00002cb0| 69 67 65 6e 74 6c 79 2e | 2e 2e 20 2a 2f 0d 09 09 |igently.|.. */...|
|00002cc0| 69 66 20 28 28 64 65 76 | 74 2d 3e 6d 65 73 73 61 |if ((dev|t->messa|
|00002cd0| 67 65 20 26 20 30 78 66 | 66 29 20 3d 3d 20 54 41 |ge & 0xf|f) == TA|
|00002ce0| 42 29 20 7b 0d 09 09 09 | 69 66 20 28 21 69 70 61 |B) {....|if (!ipa|
|00002cf0| 64 64 72 76 69 73 29 20 | 7b 0d 09 09 09 09 64 65 |ddrvis) |{.....de|
|00002d00| 76 74 2d 3e 77 68 61 74 | 20 3d 20 6e 75 6c 6c 45 |vt->what| = nullE|
|00002d10| 76 65 6e 74 3b 09 2f 2a | 20 69 67 6e 6f 72 65 20 |vent;./*| ignore |
|00002d20| 74 68 65 20 6b 65 79 20 | 2a 2f 0d 09 09 09 09 72 |the key |*/.....r|
|00002d30| 65 74 75 72 6e 28 28 42 | 6f 6f 6c 65 61 6e 29 20 |eturn((B|oolean) |
|00002d40| 46 41 4c 53 45 29 3b 0d | 09 09 09 7d 0d 09 09 09 |FALSE);.|...}....|
|00002d50| 0d 09 09 7d 0d 23 65 6e | 64 69 66 0d 09 7d 0d 09 |...}.#en|dif..}..|
|00002d60| 65 6c 73 65 20 69 66 20 | 28 64 65 76 74 2d 3e 77 |else if |(devt->w|
|00002d70| 68 61 74 20 3d 3d 20 61 | 63 74 69 76 61 74 65 45 |hat == a|ctivateE|
|00002d80| 76 74 20 26 26 20 64 65 | 76 74 2d 3e 6d 65 73 73 |vt && de|vt->mess|
|00002d90| 61 67 65 20 3d 3d 20 64 | 70 74 72 29 20 7b 0d 09 |age == d|ptr) {..|
|00002da0| 09 47 72 61 66 50 74 72 | 20 6f 6c 64 70 6f 72 74 |.GrafPtr| oldport|
|00002db0| 3b 0d 0d 09 09 69 66 20 | 28 6d 79 45 76 65 6e 74 |;....if |(myEvent|
|00002dc0| 2e 6d 6f 64 69 66 69 65 | 72 73 20 26 20 61 63 74 |.modifie|rs & act|
|00002dd0| 69 76 65 46 6c 61 67 29 | 20 7b 0d 09 09 09 47 65 |iveFlag)| {....Ge|
|00002de0| 74 50 6f 72 74 28 26 6f | 6c 64 70 6f 72 74 29 3b |tPort(&o|ldport);|
|00002df0| 0d 09 09 09 53 65 74 50 | 6f 72 74 28 64 70 74 72 |....SetP|ort(dptr|
|00002e00| 29 3b 0d 09 0d 09 09 09 | 62 75 74 68 69 6c 69 74 |);......|buthilit|
|00002e10| 65 28 26 6f 6b 72 65 63 | 74 29 3b 0d 09 0d 09 09 |e(&okrec|t);.....|
|00002e20| 09 53 65 74 50 6f 72 74 | 28 6f 6c 64 70 6f 72 74 |.SetPort|(oldport|
|00002e30| 29 3b 0d 09 09 7d 0d 09 | 7d 0d 09 65 6c 73 65 20 |);...}..|}..else |
|00002e40| 69 66 20 28 64 65 76 74 | 2d 3e 77 68 61 74 20 3d |if (devt|->what =|
|00002e50| 3d 20 75 70 64 61 74 65 | 45 76 74 20 26 26 20 64 |= update|Evt && d|
|00002e60| 65 76 74 2d 3e 6d 65 73 | 73 61 67 65 20 3d 3d 20 |evt->mes|sage == |
|00002e70| 64 70 74 72 29 20 7b 0d | 09 09 47 72 61 66 50 74 |dptr) {.|..GrafPt|
|00002e80| 72 20 6f 6c 64 70 6f 72 | 74 3b 0d 0d 09 09 47 65 |r oldpor|t;....Ge|
|00002e90| 74 50 6f 72 74 28 26 6f | 6c 64 70 6f 72 74 29 3b |tPort(&o|ldport);|
|00002ea0| 0d 09 09 53 65 74 50 6f | 72 74 28 64 70 74 72 29 |...SetPo|rt(dptr)|
|00002eb0| 3b 0d 0d 09 09 2f 2a 20 | 42 65 67 69 6e 55 70 64 |;..../* |BeginUpd|
|00002ec0| 61 74 65 28 64 70 74 72 | 29 3b 20 2a 2f 0d 09 09 |ate(dptr|); */...|
|00002ed0| 62 75 74 68 69 6c 69 74 | 65 28 26 6f 6b 72 65 63 |buthilit|e(&okrec|
|00002ee0| 74 29 3b 3b 0d 09 09 2f | 2a 20 46 72 61 6d 65 52 |t);;.../|* FrameR|
|00002ef0| 65 63 74 28 26 6c 69 73 | 74 72 65 63 74 29 3b 0d |ect(&lis|trect);.|
|00002f00| 09 09 09 6d 61 6b 65 20 | 61 20 62 6f 78 20 61 72 |...make |a box ar|
|00002f10| 6f 75 6e 64 20 74 68 65 | 20 6c 69 73 74 20 2a 2f |ound the| list */|
|00002f20| 0d 0d 09 09 2f 2a 20 45 | 6e 64 55 70 64 61 74 65 |..../* E|ndUpdate|
|00002f30| 28 64 70 74 72 29 3b 20 | 2a 2f 0d 09 09 53 65 74 |(dptr); |*/...Set|
|00002f40| 50 6f 72 74 28 6f 6c 64 | 70 6f 72 74 29 3b 0d 09 |Port(old|port);..|
|00002f50| 7d 0d 09 65 6c 73 65 0d | 09 09 64 65 66 61 75 6c |}..else.|..defaul|
|00002f60| 74 65 76 65 6e 74 28 64 | 65 76 74 29 3b 0d 09 72 |tevent(d|evt);..r|
|00002f70| 65 74 75 72 6e 28 28 42 | 6f 6f 6c 65 61 6e 29 20 |eturn((B|oolean) |
|00002f80| 46 41 4c 53 45 29 3b 0d | 7d 0d 0d 0d 0d 6e 61 6d |FALSE);.|}....nam|
|00002f90| 65 77 69 6e 64 6f 77 28 | 29 20 0d 7b 0d 09 44 69 |ewindow(|) .{..Di|
|00002fa0| 61 6c 6f 67 50 74 72 20 | 09 09 6e 6d 64 70 74 72 |alogPtr |..nmdptr|
|00002fb0| 3b 0d 09 48 61 6e 64 6c | 65 09 09 09 68 6e 61 6d |;..Handl|e...hnam|
|00002fc0| 65 3b 09 2f 2a 20 64 69 | 61 6c 6f 67 20 68 6f 73 |e;./* di|alog hos|
|00002fd0| 74 6e 61 6d 65 20 68 61 | 6e 64 6c 65 20 2a 2f 0d |tname ha|ndle */.|
|00002fe0| 09 48 61 6e 64 6c 65 09 | 09 09 68 61 64 64 72 3b |.Handle.|..haddr;|
|00002ff0| 09 2f 2a 20 64 69 61 6c | 6f 67 20 68 6f 73 74 61 |./* dial|og hosta|
|00003000| 64 64 72 65 73 73 20 68 | 61 6e 64 6c 65 20 2a 2f |ddress h|andle */|
|00003010| 0d 09 48 61 6e 64 6c 65 | 09 09 09 68 69 62 6d 6b |..Handle|...hibmk|
|00003020| 65 79 3b 09 2f 2a 20 64 | 69 61 6c 6f 67 20 68 6f |ey;./* d|ialog ho|
|00003030| 73 74 61 64 64 72 65 73 | 73 20 68 61 6e 64 6c 65 |staddres|s handle|
|00003040| 20 2a 2f 0d 09 48 61 6e | 64 6c 65 09 09 09 68 61 | */..Han|dle...ha|
|00003050| 64 64 72 74 69 74 3b 09 | 2f 2a 20 64 69 61 6c 6f |ddrtit;.|/* dialo|
|00003060| 67 20 68 6f 73 74 61 64 | 64 72 65 73 73 20 74 69 |g hostad|dress ti|
|00003070| 74 6c 65 20 2a 2f 0d 0d | 09 53 74 72 32 35 35 09 |tle */..|.Str255.|
|00003080| 09 73 74 72 68 6f 73 74 | 6e 61 6d 65 3b 09 09 2f |.strhost|name;../|
|00003090| 2a 20 6e 61 6d 65 20 6f | 66 20 68 6f 73 74 20 61 |* name o|f host a|
|000030a0| 73 20 73 74 72 69 6e 67 | 20 2a 2f 0d 09 53 74 72 |s string| */..Str|
|000030b0| 32 35 35 09 09 73 74 72 | 68 6f 73 74 61 64 64 72 |255..str|hostaddr|
|000030c0| 3b 09 09 2f 2a 20 61 64 | 64 72 65 73 73 20 6f 66 |;../* ad|dress of|
|000030d0| 20 68 6f 73 74 20 61 73 | 20 73 74 72 69 6e 67 20 | host as| string |
|000030e0| 2a 2f 0d 09 53 74 72 32 | 35 35 09 09 73 74 72 68 |*/..Str2|55..strh|
|000030f0| 6f 73 74 61 64 64 72 74 | 69 74 3b 09 09 2f 2a 20 |ostaddrt|it;../* |
|00003100| 61 64 64 72 65 73 73 20 | 6f 66 20 68 6f 73 74 20 |address |of host |
|00003110| 74 69 74 6c 65 20 2a 2f | 0d 09 48 61 6e 64 6c 65 |title */|..Handle|
|00003120| 09 09 74 69 74 6c 65 3b | 0d 09 48 61 6e 64 6c 65 |..title;|..Handle|
|00003130| 09 09 68 6d 79 61 64 64 | 72 3b 09 09 2f 2a 20 64 |..hmyadd|r;../* d|
|00003140| 69 61 6c 6f 67 20 68 6f | 73 74 61 64 64 72 65 73 |ialog ho|staddres|
|00003150| 73 20 68 61 6e 64 6c 65 | 20 2a 2f 0d 09 48 61 6e |s handle| */..Han|
|00003160| 64 6c 65 09 09 68 67 61 | 74 65 61 64 64 72 3b 09 |dle..hga|teaddr;.|
|00003170| 2f 2a 20 64 69 61 6c 6f | 67 20 68 6f 73 74 61 64 |/* dialo|g hostad|
|00003180| 64 72 65 73 73 20 68 61 | 6e 64 6c 65 20 2a 2f 0d |dress ha|ndle */.|
|00003190| 09 48 61 6e 64 6c 65 09 | 09 68 6f 6b 3b 09 09 09 |.Handle.|.hok;...|
|000031a0| 09 2f 2a 20 6f 6b 20 62 | 75 74 74 6f 6e 20 2a 2f |./* ok b|utton */|
|000031b0| 0d 09 0d 09 47 72 61 66 | 50 74 72 09 09 6f 70 6f |....Graf|Ptr..opo|
|000031c0| 72 74 3b 0d 09 69 6e 74 | 09 09 09 69 74 65 6d 5f |rt;..int|...item_|
|000031d0| 69 64 3b 09 09 2f 2a 20 | 69 74 65 6d 20 74 68 61 |id;../* |item tha|
|000031e0| 74 20 77 61 73 20 74 6f | 75 63 68 65 64 20 2a 2f |t was to|uched */|
|000031f0| 0d 09 69 6e 74 09 09 09 | 6c 65 6e 3b 0d 09 73 68 |..int...|len;..sh|
|00003200| 6f 72 74 09 09 63 6f 75 | 6e 74 3b 0d 09 69 6e 74 |ort..cou|nt;..int|
|00003210| 09 09 09 74 79 70 65 3b | 09 09 09 2f 2a 20 67 65 |...type;|.../* ge|
|00003220| 6e 65 72 61 6c 20 70 75 | 72 70 6f 73 65 20 67 65 |neral pu|rpose ge|
|00003230| 74 64 69 74 65 6d 20 76 | 61 72 73 20 2a 2f 0d 09 |tditem v|ars */..|
|00003240| 48 61 6e 64 6c 65 09 09 | 68 69 74 65 6d 3b 0d 09 |Handle..|hitem;..|
|00003250| 52 65 63 74 09 09 72 65 | 63 74 3b 0d 09 0d 09 73 |Rect..re|ct;....s|
|00003260| 68 6f 72 74 09 09 74 65 | 72 6d 69 6e 64 65 78 3b |hort..te|rmindex;|
|00003270| 0d 09 63 68 61 72 09 09 | 6f 64 69 73 61 62 6c 65 |..char..|odisable|
|00003280| 74 65 72 6d 5b 54 45 52 | 4d 54 59 50 45 4d 41 58 |term[TER|MTYPEMAX|
|00003290| 5d 3b 0d 09 73 68 6f 72 | 74 09 09 74 65 6d 70 63 |];..shor|t..tempc|
|000032a0| 6f 6e 6e 74 79 70 65 3b | 0d 09 73 68 6f 72 74 09 |onntype;|..short.|
|000032b0| 09 6f 69 62 6d 6b 65 79 | 3b 0d 09 73 68 6f 72 74 |.oibmkey|;..short|
|000032c0| 09 09 6f 6e 65 77 63 6f | 6e 66 3b 0d 09 73 68 6f |..onewco|nf;..sho|
|000032d0| 72 74 20 6e 6d 63 75 74 | 63 70 3b 09 09 09 09 2f |rt nmcut|cp;..../|
|000032e0| 2a 20 43 6f 72 6e 65 6c | 6c 20 54 43 50 20 69 73 |* Cornel|l TCP is|
|000032f0| 20 73 65 6c 65 63 74 65 | 64 20 69 66 20 54 52 55 | selecte|d if TRU|
|00003300| 45 20 2a 2f 0d 09 73 68 | 6f 72 74 20 66 69 72 73 |E */..sh|ort firs|
|00003310| 74 74 65 72 6d 20 3d 20 | 46 41 4c 53 45 3b 0d 09 |tterm = |FALSE;..|
|00003320| 0d 09 2f 2a 20 65 6c 73 | 65 20 6c 61 75 6e 63 68 |../* els|e launch|
|00003330| 65 64 20 64 69 72 65 63 | 74 20 66 72 6f 6d 20 61 |ed direc|t from a|
|00003340| 70 70 6c 69 63 61 74 69 | 6f 6e 20 6f 72 20 6e 6f |pplicati|on or no|
|00003350| 20 68 6f 73 74 20 6e 61 | 6d 65 20 65 78 69 73 74 | host na|me exist|
|00003360| 73 2c 20 64 6f 20 74 68 | 65 20 64 69 61 6c 6f 67 |s, do th|e dialog|
|00003370| 20 2a 2f 0d 09 69 66 20 | 28 63 68 6b 62 61 63 6b | */..if |(chkback|
|00003380| 67 72 6f 75 6e 64 28 29 | 29 0d 09 09 72 65 74 75 |ground()|)...retu|
|00003390| 72 6e 28 2d 31 29 3b 0d | 0d 09 47 65 74 50 6f 72 |rn(-1);.|..GetPor|
|000033a0| 74 28 26 6f 70 6f 72 74 | 29 3b 0d 09 65 6d 77 64 |t(&oport|);..emwd|
|000033b0| 65 61 63 74 69 76 61 74 | 65 28 29 3b 0d 09 0d 09 |eactivat|e();....|
|000033c0| 69 66 20 28 28 6e 6d 64 | 70 74 72 20 3d 20 47 65 |if ((nmd|ptr = Ge|
|000033d0| 74 4e 65 77 44 69 61 6c | 6f 67 28 44 4e 45 57 57 |tNewDial|og(DNEWW|
|000033e0| 49 4e 44 2c 20 4e 55 4c | 4c 2c 20 28 57 69 6e 64 |IND, NUL|L, (Wind|
|000033f0| 6f 77 50 74 72 29 20 28 | 2d 31 29 29 29 20 3d 3d |owPtr) (|-1))) ==|
|00003400| 20 4e 55 4c 4c 29 0d 09 | 09 72 65 74 75 72 6e 28 | NULL)..|.return(|
|00003410| 2d 31 29 3b 0d 0d 09 63 | 65 6e 74 65 72 77 69 6e |-1);...c|enterwin|
|00003420| 64 28 6e 6d 64 70 74 72 | 29 3b 0d 09 0d 09 6d 6f |d(nmdptr|);....mo|
|00003430| 64 61 6c 64 69 61 6c 6f | 67 20 3d 20 54 52 55 45 |daldialo|g = TRUE|
|00003440| 3b 0d 09 53 65 74 43 75 | 72 73 6f 72 28 26 61 72 |;..SetCu|rsor(&ar|
|00003450| 72 6f 77 29 3b 0d 09 0d | 09 73 68 6f 77 63 75 72 |row);...|.showcur|
|00003460| 73 6f 72 28 29 3b 0d 09 | 0d 09 53 65 74 50 6f 72 |sor();..|..SetPor|
|00003470| 74 28 6e 6d 64 70 74 72 | 29 3b 0d 0d 09 2f 2a 20 |t(nmdptr|);.../* |
|00003480| 73 61 76 65 20 74 68 65 | 20 73 74 61 74 65 20 6f |save the| state o|
|00003490| 66 20 74 68 69 6e 67 73 | 20 77 65 20 6d 6f 64 69 |f things| we modi|
|000034a0| 66 79 20 69 6e 20 63 61 | 73 65 20 77 65 20 43 61 |fy in ca|se we Ca|
|000034b0| 6e 63 65 6c 20 2a 2f 0d | 09 66 6f 72 20 28 63 6f |ncel */.|.for (co|
|000034c0| 75 6e 74 20 3d 20 30 3b | 20 63 6f 75 6e 74 20 3c |unt = 0;| count <|
|000034d0| 20 54 45 52 4d 54 59 50 | 45 43 4f 55 4e 54 3b 20 | TERMTYP|ECOUNT; |
|000034e0| 63 6f 75 6e 74 2b 2b 29 | 20 7b 0d 09 09 6f 64 69 |count++)| {...odi|
|000034f0| 73 61 62 6c 65 74 65 72 | 6d 5b 63 6f 75 6e 74 5d |sableter|m[count]|
|00003500| 20 3d 20 65 6d 64 70 2d | 3e 64 69 73 61 62 6c 65 | = emdp-|>disable|
|00003510| 74 65 72 6d 5b 63 6f 75 | 6e 74 5d 3b 0d 09 7d 0d |term[cou|nt];..}.|
|00003520| 09 74 65 6d 70 63 6f 6e | 6e 74 79 70 65 20 3d 20 |.tempcon|ntype = |
|00003530| 65 6d 64 70 2d 3e 63 6f | 6e 6e 74 79 70 65 3b 0d |emdp->co|nntype;.|
|00003540| 09 6f 69 62 6d 6b 65 79 | 20 3d 20 65 6d 64 70 2d |.oibmkey| = emdp-|
|00003550| 3e 69 62 6d 5f 6b 65 79 | 6d 6f 64 65 3b 0d 0d 0d |>ibm_key|mode;...|
|00003560| 09 47 65 74 44 49 74 65 | 6d 28 6e 6d 64 70 74 72 |.GetDIte|m(nmdptr|
|00003570| 2c 20 4f 4b 42 2c 20 26 | 74 79 70 65 2c 20 26 68 |, OKB, &|type, &h|
|00003580| 69 74 65 6d 2c 20 26 6f | 6b 72 65 63 74 29 3b 0d |item, &o|krect);.|
|00003590| 09 62 75 74 68 69 6c 69 | 74 65 28 26 6f 6b 72 65 |.buthili|te(&okre|
|000035a0| 63 74 29 3b 0d 09 0d 09 | 2f 2a 20 77 69 6e 64 6f |ct);....|/* windo|
|000035b0| 77 20 6e 61 6d 65 20 2a | 2f 0d 09 47 65 74 44 49 |w name *|/..GetDI|
|000035c0| 74 65 6d 28 6e 6d 64 70 | 74 72 2c 20 4e 4d 5f 48 |tem(nmdp|tr, NM_H|
|000035d0| 4f 53 54 4e 41 4d 45 2c | 20 26 74 79 70 65 2c 20 |OSTNAME,| &type, |
|000035e0| 26 68 6e 61 6d 65 2c 20 | 26 72 65 63 74 29 3b 0d |&hname, |&rect);.|
|000035f0| 09 69 66 20 28 65 6d 64 | 70 2d 3e 68 68 6f 73 74 |.if (emd|p->hhost|
|00003600| 6e 61 6d 65 29 20 7b 0d | 09 09 2f 2a 20 70 61 73 |name) {.|../* pas|
|00003610| 74 65 20 74 68 65 20 6e | 61 6d 65 20 69 6e 20 2a |te the n|ame in *|
|00003620| 2f 0d 09 09 48 4c 6f 63 | 6b 28 65 6d 64 70 2d 3e |/...HLoc|k(emdp->|
|00003630| 68 68 6f 73 74 6e 61 6d | 65 29 3b 0d 09 09 53 65 |hhostnam|e);...Se|
|00003640| 74 49 54 65 78 74 28 68 | 6e 61 6d 65 2c 20 2a 65 |tIText(h|name, *e|
|00003650| 6d 64 70 2d 3e 68 68 6f | 73 74 6e 61 6d 65 29 3b |mdp->hho|stname);|
|00003660| 0d 09 09 48 55 6e 6c 6f | 63 6b 28 65 6d 64 70 2d |...HUnlo|ck(emdp-|
|00003670| 3e 68 68 6f 73 74 6e 61 | 6d 65 29 3b 0d 09 7d 0d |>hhostna|me);..}.|
|00003680| 0d 09 2f 2a 20 49 50 20 | 68 6f 73 74 20 61 64 64 |../* IP |host add|
|00003690| 72 65 73 73 20 69 66 20 | 61 6e 79 20 2a 2f 0d 09 |ress if |any */..|
|000036a0| 47 65 74 44 49 74 65 6d | 28 6e 6d 64 70 74 72 2c |GetDItem|(nmdptr,|
|000036b0| 20 4e 4d 5f 48 4f 53 54 | 41 44 44 52 2c 20 26 74 | NM_HOST|ADDR, &t|
|000036c0| 79 70 65 2c 20 26 68 61 | 64 64 72 2c 20 26 72 65 |ype, &ha|ddr, &re|
|000036d0| 63 74 29 3b 0d 09 69 66 | 20 28 65 6d 64 70 2d 3e |ct);..if| (emdp->|
|000036e0| 68 6c 61 73 74 68 6f 73 | 74 29 20 7b 0d 09 09 2f |hlasthos|t) {.../|
|000036f0| 2a 20 70 61 73 74 65 20 | 74 68 65 20 61 64 64 72 |* paste |the addr|
|00003700| 65 73 73 20 69 6e 20 2a | 2f 0d 09 09 48 4c 6f 63 |ess in *|/...HLoc|
|00003710| 6b 28 65 6d 64 70 2d 3e | 68 6c 61 73 74 68 6f 73 |k(emdp->|hlasthos|
|00003720| 74 29 3b 0d 09 09 63 74 | 6f 70 28 2a 65 6d 64 70 |t);...ct|op(*emdp|
|00003730| 2d 3e 68 6c 61 73 74 68 | 6f 73 74 29 3b 0d 09 09 |->hlasth|ost);...|
|00003740| 53 65 74 49 54 65 78 74 | 28 68 61 64 64 72 2c 20 |SetIText|(haddr, |
|00003750| 2a 65 6d 64 70 2d 3e 68 | 6c 61 73 74 68 6f 73 74 |*emdp->h|lasthost|
|00003760| 29 3b 0d 09 09 70 74 6f | 63 28 2a 65 6d 64 70 2d |);...pto|c(*emdp-|
|00003770| 3e 68 6c 61 73 74 68 6f | 73 74 29 3b 0d 09 09 48 |>hlastho|st);...H|
|00003780| 55 6e 6c 6f 63 6b 28 65 | 6d 64 70 2d 3e 68 6c 61 |Unlock(e|mdp->hla|
|00003790| 73 74 68 6f 73 74 29 3b | 0d 09 7d 0d 0d 09 47 65 |sthost);|..}...Ge|
|000037a0| 74 44 49 74 65 6d 28 6e | 6d 64 70 74 72 2c 20 4e |tDItem(n|mdptr, N|
|000037b0| 4d 5f 48 4f 53 54 41 44 | 44 52 54 49 54 2c 20 26 |M_HOSTAD|DRTIT, &|
|000037c0| 74 79 70 65 2c 20 26 68 | 61 64 64 72 74 69 74 2c |type, &h|addrtit,|
|000037d0| 20 26 72 65 63 74 29 3b | 0d 09 0d 09 2f 2a 20 69 | &rect);|..../* i|
|000037e0| 62 6d 20 6b 65 79 20 69 | 6e 74 65 72 70 72 65 74 |bm key i|nterpret|
|000037f0| 61 74 69 6f 6e 20 6d 6f | 64 65 20 66 6f 72 20 41 |ation mo|de for A|
|00003800| 53 43 49 49 20 37 31 37 | 31 20 61 63 63 65 73 73 |SCII 717|1 access|
|00003810| 20 2a 2f 0d 09 47 65 74 | 44 49 74 65 6d 28 6e 6d | */..Get|DItem(nm|
|00003820| 64 70 74 72 2c 20 4e 4d | 5f 49 42 4d 4b 45 59 2c |dptr, NM|_IBMKEY,|
|00003830| 20 26 74 79 70 65 2c 20 | 26 68 69 62 6d 6b 65 79 | &type, |&hibmkey|
|00003840| 2c 20 26 72 65 63 74 29 | 3b 0d 09 69 66 20 28 65 |, &rect)|;..if (e|
|00003850| 6d 64 70 2d 3e 69 62 6d | 5f 6b 65 79 6d 6f 64 65 |mdp->ibm|_keymode|
|00003860| 29 0d 09 09 53 65 74 43 | 74 6c 56 61 6c 75 65 28 |)...SetC|tlValue(|
|00003870| 68 69 62 6d 6b 65 79 2c | 20 31 29 3b 0d 0d 09 2f |hibmkey,| 1);.../|
|00003880| 2a 20 64 69 73 61 62 6c | 65 20 74 68 65 20 43 6f |* disabl|e the Co|
|00003890| 6e 6e 20 4d 67 72 20 6f | 70 74 69 6f 6e 20 75 6e |nn Mgr o|ption un|
|000038a0| 74 69 6c 20 69 74 20 77 | 6f 72 6b 73 20 2a 2f 0d |til it w|orks */.|
|000038b0| 09 47 65 74 44 49 74 65 | 6d 28 6e 6d 64 70 74 72 |.GetDIte|m(nmdptr|
|000038c0| 2c 20 4e 4d 5f 43 4f 4e | 4e 2c 20 26 74 79 70 65 |, NM_CON|N, &type|
|000038d0| 2c 20 26 68 69 74 65 6d | 2c 20 26 72 65 63 74 29 |, &hitem|, &rect)|
|000038e0| 3b 0d 09 48 69 6c 69 74 | 65 43 6f 6e 74 72 6f 6c |;..Hilit|eControl|
|000038f0| 28 68 69 74 65 6d 2c 20 | 32 35 35 29 3b 0d 09 0d |(hitem, |255);...|
|00003900| 09 2f 2a 20 53 65 6c 65 | 63 74 20 74 68 65 20 4e |./* Sele|ct the N|
|00003910| 61 6d 65 20 54 65 78 74 | 20 22 55 6e 74 69 74 6c |ame Text| "Untitl|
|00003920| 65 64 22 20 6f 72 20 77 | 68 61 74 65 76 65 72 20 |ed" or w|hatever |
|00003930| 2a 2f 0d 09 53 65 6c 49 | 54 65 78 74 28 6e 6d 64 |*/..SelI|Text(nmd|
|00003940| 70 74 72 2c 20 4e 4d 5f | 48 4f 53 54 4e 41 4d 45 |ptr, NM_|HOSTNAME|
|00003950| 2c 20 30 2c 20 31 30 30 | 30 29 3b 0d 0d 0d 23 69 |, 0, 100|0);...#i|
|00003960| 66 64 65 66 20 44 55 41 | 4c 54 43 50 0d 09 2f 2a |fdef DUA|LTCP../*|
|00003970| 20 73 68 6f 77 20 74 68 | 65 20 63 75 72 72 65 6e | show th|e curren|
|00003980| 74 20 63 6f 6e 6e 65 63 | 74 69 6f 6e 20 74 79 70 |t connec|tion typ|
|00003990| 65 20 2a 2f 0d 0d 09 69 | 66 20 28 65 6d 64 70 2d |e */...i|f (emdp-|
|000039a0| 3e 63 6f 6e 6e 74 79 70 | 65 20 3d 3d 20 43 4f 4e |>conntyp|e == CON|
|000039b0| 4e 5f 4d 41 43 54 43 50 | 29 20 7b 0d 09 09 2f 2a |N_MACTCP|) {.../*|
|000039c0| 20 73 68 6f 77 20 4d 61 | 63 54 43 50 20 65 6e 61 | show Ma|cTCP ena|
|000039d0| 62 6c 65 64 20 2a 2f 0d | 09 09 47 65 74 44 49 74 |bled */.|..GetDIt|
|000039e0| 65 6d 28 6e 6d 64 70 74 | 72 2c 20 4e 4d 5f 43 55 |em(nmdpt|r, NM_CU|
|000039f0| 54 43 50 2c 20 26 74 79 | 70 65 2c 20 26 68 69 74 |TCP, &ty|pe, &hit|
|00003a00| 65 6d 2c 20 26 72 65 63 | 74 29 3b 0d 09 09 53 65 |em, &rec|t);...Se|
|00003a10| 74 43 74 6c 56 61 6c 75 | 65 28 68 69 74 65 6d 2c |tCtlValu|e(hitem,|
|00003a20| 20 31 29 3b 0d 09 09 6e | 6d 63 75 74 63 70 20 3d | 1);...n|mcutcp =|
|00003a30| 20 46 41 4c 53 45 3b 0d | 09 7d 0d 09 65 6c 73 65 | FALSE;.|.}..else|
|00003a40| 20 7b 0d 09 09 69 66 20 | 28 65 6d 64 70 2d 3e 63 | {...if |(emdp->c|
|00003a50| 6f 6e 6e 74 79 70 65 20 | 3d 3d 20 43 4f 4e 4e 5f |onntype |== CONN_|
|00003a60| 43 55 54 43 50 29 20 7b | 0d 09 09 09 2f 2a 20 66 |CUTCP) {|..../* f|
|00003a70| 61 6b 65 20 69 74 20 2a | 2f 0d 09 09 09 74 65 6d |ake it *|/....tem|
|00003a80| 70 63 6f 6e 6e 74 79 70 | 65 20 3d 20 43 4f 4e 4e |pconntyp|e = CONN|
|00003a90| 5f 4d 41 43 54 43 50 3b | 0d 09 09 7d 0d 09 09 6e |_MACTCP;|...}...n|
|00003aa0| 6d 63 75 74 63 70 20 3d | 20 54 52 55 45 3b 0d 09 |mcutcp =| TRUE;..|
|00003ab0| 7d 0d 23 65 6c 73 65 0d | 09 69 66 20 28 65 6d 64 |}.#else.|.if (emd|
|00003ac0| 70 2d 3e 63 6f 6e 6e 74 | 79 70 65 20 3d 3d 20 43 |p->connt|ype == C|
|00003ad0| 4f 4e 4e 5f 43 55 54 43 | 50 29 20 7b 0d 09 09 2f |ONN_CUTC|P) {.../|
|00003ae0| 2a 20 66 6f 72 63 65 20 | 69 74 20 2a 2f 0d 09 09 |* force |it */...|
|00003af0| 65 6d 64 70 2d 3e 63 6f | 6e 6e 74 79 70 65 20 3d |emdp->co|nntype =|
|00003b00| 20 43 4f 4e 4e 5f 4d 41 | 43 54 43 50 3b 0d 09 09 | CONN_MA|CTCP;...|
|00003b10| 74 65 6d 70 63 6f 6e 6e | 74 79 70 65 20 3d 20 43 |tempconn|type = C|
|00003b20| 4f 4e 4e 5f 4d 41 43 54 | 43 50 3b 0d 09 7d 0d 09 |ONN_MACT|CP;..}..|
|00003b30| 6e 6d 63 75 74 63 70 20 | 3d 20 46 41 4c 53 45 3b |nmcutcp |= FALSE;|
|00003b40| 0d 0d 09 2f 2a 20 68 69 | 64 65 20 4d 61 63 54 43 |.../* hi|de MacTC|
|00003b50| 50 20 63 6f 6e 74 72 6f | 6c 2c 20 73 69 6e 63 65 |P contro|l, since|
|00003b60| 20 77 65 20 61 6c 77 61 | 79 73 20 75 73 65 20 6d | we alwa|ys use m|
|00003b70| 61 63 54 43 50 20 2a 2f | 0d 09 47 65 74 44 49 74 |acTCP */|..GetDIt|
|00003b80| 65 6d 28 6e 6d 64 70 74 | 72 2c 20 4e 4d 5f 43 55 |em(nmdpt|r, NM_CU|
|00003b90| 54 43 50 2c 20 26 74 79 | 70 65 2c 20 26 68 69 74 |TCP, &ty|pe, &hit|
|00003ba0| 65 6d 2c 20 26 72 65 63 | 74 29 3b 0d 09 48 69 64 |em, &rec|t);..Hid|
|00003bb0| 65 43 6f 6e 74 72 6f 6c | 28 68 69 74 65 6d 29 3b |eControl|(hitem);|
|00003bc0| 0d 09 47 65 74 44 49 74 | 65 6d 28 6e 6d 64 70 74 |..GetDIt|em(nmdpt|
|00003bd0| 72 2c 20 4e 4d 5f 54 43 | 50 2c 20 26 74 79 70 65 |r, NM_TC|P, &type|
|00003be0| 2c 20 26 68 69 74 65 6d | 2c 20 26 72 65 63 74 29 |, &hitem|, &rect)|
|00003bf0| 3b 0d 09 53 65 74 43 54 | 69 74 6c 65 28 68 69 74 |;..SetCT|itle(hit|
|00003c00| 65 6d 2c 20 22 5c 50 4d | 61 63 54 43 50 20 54 65 |em, "\PM|acTCP Te|
|00003c10| 6c 6e 65 74 22 29 3b 0d | 0d 23 65 6e 64 69 66 0d |lnet");.|.#endif.|
|00003c20| 09 0d 09 2f 2a 20 73 68 | 6f 77 20 74 68 65 20 63 |.../* sh|ow the c|
|00003c30| 75 72 72 65 6e 74 20 63 | 6f 6e 6e 65 63 74 69 6f |urrent c|onnectio|
|00003c40| 6e 20 74 79 70 65 20 2a | 2f 0d 09 69 66 20 28 65 |n type *|/..if (e|
|00003c50| 6d 64 70 2d 3e 63 6f 6e | 6e 74 79 70 65 20 3d 3d |mdp->con|ntype ==|
|00003c60| 20 43 4f 4e 4e 5f 4d 41 | 43 54 43 50 20 7c 7c 20 | CONN_MA|CTCP || |
|00003c70| 65 6d 64 70 2d 3e 63 6f | 6e 6e 74 79 70 65 20 3d |emdp->co|nntype =|
|00003c80| 3d 20 43 4f 4e 4e 5f 43 | 55 54 43 50 29 20 7b 0d |= CONN_C|UTCP) {.|
|00003c90| 09 09 47 65 74 44 49 74 | 65 6d 28 6e 6d 64 70 74 |..GetDIt|em(nmdpt|
|00003ca0| 72 2c 20 4e 4d 5f 54 43 | 50 2c 20 26 74 79 70 65 |r, NM_TC|P, &type|
|00003cb0| 2c 20 26 68 69 74 65 6d | 2c 20 26 72 65 63 74 29 |, &hitem|, &rect)|
|00003cc0| 3b 0d 09 09 53 65 74 43 | 74 6c 56 61 6c 75 65 28 |;...SetC|tlValue(|
|00003cd0| 68 69 74 65 6d 2c 20 31 | 29 3b 0d 09 09 6e 6d 73 |hitem, 1|);...nms|
|00003ce0| 65 74 74 63 70 28 6e 6d | 64 70 74 72 2c 20 54 52 |ettcp(nm|dptr, TR|
|00003cf0| 55 45 29 3b 0d 09 7d 0d | 09 65 6c 73 65 20 69 66 |UE);..}.|.else if|
|00003d00| 20 28 65 6d 64 70 2d 3e | 63 6f 6e 6e 74 79 70 65 | (emdp->|conntype|
|00003d10| 20 3d 3d 20 43 4f 4e 4e | 5f 53 45 52 44 29 20 7b | == CONN|_SERD) {|
|00003d20| 0d 09 09 47 65 74 44 49 | 74 65 6d 28 6e 6d 64 70 |...GetDI|tem(nmdp|
|00003d30| 74 72 2c 20 65 6d 64 70 | 2d 3e 75 73 65 62 70 6f |tr, emdp|->usebpo|
|00003d40| 72 74 20 3f 20 4e 4d 5f | 53 45 52 44 42 20 3a 20 |rt ? NM_|SERDB : |
|00003d50| 4e 4d 5f 53 45 52 44 41 | 2c 20 26 74 79 70 65 2c |NM_SERDA|, &type,|
|00003d60| 20 26 68 69 74 65 6d 2c | 20 26 72 65 63 74 29 3b | &hitem,| &rect);|
|00003d70| 0d 09 09 53 65 74 43 74 | 6c 56 61 6c 75 65 28 68 |...SetCt|lValue(h|
|00003d80| 69 74 65 6d 2c 20 31 29 | 3b 0d 09 09 6e 6d 73 65 |item, 1)|;...nmse|
|00003d90| 74 74 63 70 28 6e 6d 64 | 70 74 72 2c 20 46 41 4c |ttcp(nmd|ptr, FAL|
|00003da0| 53 45 29 3b 0d 09 7d 0d | 09 65 6c 73 65 20 69 66 |SE);..}.|.else if|
|00003db0| 20 28 65 6d 64 70 2d 3e | 63 6f 6e 6e 74 79 70 65 | (emdp->|conntype|
|00003dc0| 20 3d 3d 20 43 4f 4e 4e | 5f 43 4f 4d 4d 4d 47 52 | == CONN|_COMMMGR|
|00003dd0| 29 20 7b 0d 09 09 47 65 | 74 44 49 74 65 6d 28 6e |) {...Ge|tDItem(n|
|00003de0| 6d 64 70 74 72 2c 20 4e | 4d 5f 43 4f 4e 4e 2c 20 |mdptr, N|M_CONN, |
|00003df0| 26 74 79 70 65 2c 20 26 | 68 69 74 65 6d 2c 20 26 |&type, &|hitem, &|
|00003e00| 72 65 63 74 29 3b 0d 09 | 09 53 65 74 43 74 6c 56 |rect);..|.SetCtlV|
|00003e10| 61 6c 75 65 28 68 69 74 | 65 6d 2c 20 31 29 3b 0d |alue(hit|em, 1);.|
|00003e20| 09 09 6e 6d 73 65 74 74 | 63 70 28 6e 6d 64 70 74 |..nmsett|cp(nmdpt|
|00003e30| 72 2c 20 46 41 4c 53 45 | 29 3b 0d 09 7d 0d 09 0d |r, FALSE|);..}...|
|00003e40| 09 2f 2a 20 73 68 6f 77 | 20 74 68 65 20 63 75 72 |./* show| the cur|
|00003e50| 72 65 6e 74 20 74 65 72 | 6d 69 6e 61 6c 20 74 79 |rent ter|minal ty|
|00003e60| 70 65 73 3b 20 61 75 74 | 6f 20 77 69 6c 6c 20 68 |pes; aut|o will h|
|00003e70| 61 76 65 20 41 4c 4c 20 | 46 41 4c 53 45 20 2a 2f |ave ALL |FALSE */|
|00003e80| 0d 09 2f 2a 20 74 68 65 | 20 6c 6f 67 69 63 20 63 |../* the| logic c|
|00003e90| 6f 75 6c 64 20 62 65 20 | 61 20 6c 69 74 74 6c 65 |ould be |a little|
|00003ea0| 20 73 69 6d 70 6c 65 72 | 2c 20 62 75 74 20 74 68 | simpler|, but th|
|00003eb0| 65 20 6f 72 69 67 69 6e | 61 6c 20 69 6e 74 65 72 |e origin|al inter|
|00003ec0| 66 61 63 65 20 61 6c 6c | 6f 77 65 64 0d 09 09 73 |face all|owed...s|
|00003ed0| 65 6c 65 63 74 69 6e 67 | 20 61 72 62 69 74 72 61 |electing| arbitra|
|00003ee0| 72 79 20 6c 69 73 74 73 | 20 6f 66 20 65 6e 61 62 |ry lists| of enab|
|00003ef0| 6c 65 64 20 74 65 72 6d | 69 6e 61 6c 73 20 72 61 |led term|inals ra|
|00003f00| 74 68 65 72 20 74 68 61 | 6e 20 0d 09 09 61 75 74 |ther tha|n ...aut|
|00003f10| 6f 20 6f 72 20 6a 75 73 | 74 20 6f 6e 65 2e 2e 2e |o or jus|t one...|
|00003f20| 20 2a 2f 0d 09 09 0d 09 | 66 6f 72 20 28 63 6f 75 | */.....|for (cou|
|00003f30| 6e 74 20 3d 20 30 2c 20 | 74 65 72 6d 69 6e 64 65 |nt = 0, |terminde|
|00003f40| 78 20 3d 20 4e 4d 5f 56 | 54 31 30 30 3b 20 63 6f |x = NM_V|T100; co|
|00003f50| 75 6e 74 20 3c 20 54 45 | 52 4d 54 59 50 45 43 4f |unt < TE|RMTYPECO|
|00003f60| 55 4e 54 3b 20 0d 09 09 | 09 63 6f 75 6e 74 2b 2b |UNT; ...|.count++|
|00003f70| 2c 20 74 65 72 6d 69 6e | 64 65 78 2b 2b 29 20 7b |, termin|dex++) {|
|00003f80| 0d 09 09 09 0d 09 09 09 | 69 66 20 28 65 6d 64 70 |........|if (emdp|
|00003f90| 2d 3e 64 69 73 61 62 6c | 65 74 65 72 6d 5b 63 6f |->disabl|eterm[co|
|00003fa0| 75 6e 74 5d 29 20 7b 0d | 09 09 09 09 69 66 20 28 |unt]) {.|....if (|
|00003fb0| 66 69 72 73 74 74 65 72 | 6d 29 0d 09 09 09 09 09 |firstter|m)......|
|00003fc0| 2f 2a 20 77 65 27 76 65 | 20 66 6f 75 6e 64 20 6f |/* we've| found o|
|00003fd0| 6e 65 20 65 6e 61 62 6c | 65 64 20 26 20 6f 6e 65 |ne enabl|ed & one|
|00003fe0| 20 64 69 73 61 62 6c 65 | 64 2c 20 6e 6f 74 20 61 | disable|d, not a|
|00003ff0| 75 74 6f 20 2a 2f 0d 09 | 09 09 09 09 62 72 65 61 |uto */..|....brea|
|00004000| 6b 3b 0d 09 09 09 09 65 | 6c 73 65 0d 09 09 09 09 |k;.....e|lse.....|
|00004010| 09 2f 2a 20 74 72 79 20 | 74 6f 20 66 69 6e 64 20 |./* try |to find |
|00004020| 61 6e 20 65 6e 61 62 6c | 65 64 20 74 65 72 6d 69 |an enabl|ed termi|
|00004030| 6e 61 6c 20 2a 2f 0d 09 | 09 09 09 09 63 6f 6e 74 |nal */..|....cont|
|00004040| 69 6e 75 65 3b 0d 09 09 | 09 7d 0d 09 09 09 65 6c |inue;...|.}....el|
|00004050| 73 65 20 7b 0d 09 09 09 | 09 69 66 20 28 21 66 69 |se {....|.if (!fi|
|00004060| 72 73 74 74 65 72 6d 29 | 20 7b 0d 09 09 09 09 09 |rstterm)| {......|
|00004070| 2f 2a 20 72 65 6d 65 6d | 62 65 72 20 74 68 65 20 |/* remem|ber the |
|00004080| 66 69 72 73 74 20 74 65 | 72 6d 69 6e 61 6c 20 77 |first te|rminal w|
|00004090| 65 20 66 69 6e 64 20 65 | 6e 61 62 6c 65 64 20 69 |e find e|nabled i|
|000040a0| 6e 20 63 61 73 65 0d 09 | 09 09 09 09 09 74 68 65 |n case..|.....the|
|000040b0| 79 20 61 72 65 6e 27 74 | 20 41 4c 4c 20 65 6e 61 |y aren't| ALL ena|
|000040c0| 62 6c 65 64 2e 2e 2e 20 | 2a 2f 0d 09 09 09 09 09 |bled... |*/......|
|000040d0| 66 69 72 73 74 74 65 72 | 6d 20 3d 20 74 65 72 6d |firstter|m = term|
|000040e0| 69 6e 64 65 78 3b 0d 09 | 09 09 09 09 69 66 20 28 |index;..|....if (|
|000040f0| 63 6f 75 6e 74 20 3d 3d | 20 28 54 45 52 4d 54 59 |count ==| (TERMTY|
|00004100| 50 45 43 4f 55 4e 54 20 | 2d 20 31 29 20 29 20 7b |PECOUNT |- 1) ) {|
|00004110| 0d 09 09 09 09 09 09 2f | 2a 20 6c 61 73 74 20 74 |......./|* last t|
|00004120| 65 72 6d 69 6e 61 6c 20 | 69 6e 20 74 68 65 20 6c |erminal |in the l|
|00004130| 69 73 74 2c 20 6d 61 6b | 65 20 73 75 72 65 20 63 |ist, mak|e sure c|
|00004140| 6f 75 6e 74 20 3c 20 54 | 45 52 4d 54 59 50 45 43 |ount < T|ERMTYPEC|
|00004150| 4f 55 4e 54 20 2a 2f 0d | 09 09 09 09 09 09 62 72 |OUNT */.|......br|
|00004160| 65 61 6b 3b 0d 09 09 09 | 09 09 7d 0d 09 09 09 09 |eak;....|..}.....|
|00004170| 7d 0d 09 09 7d 0d 09 7d | 0d 09 69 66 20 28 63 6f |}...}..}|..if (co|
|00004180| 75 6e 74 20 3e 3d 20 54 | 45 52 4d 54 59 50 45 43 |unt >= T|ERMTYPEC|
|00004190| 4f 55 4e 54 29 20 7b 0d | 09 09 2f 2a 20 61 6c 6c |OUNT) {.|../* all|
|000041a0| 20 6f 72 20 6e 6f 6e 65 | 20 77 65 72 65 20 73 65 | or none| were se|
|000041b0| 6c 65 63 74 65 64 2c 20 | 73 65 6c 65 63 74 20 74 |lected, |select t|
|000041c0| 68 65 20 74 65 72 6d 69 | 6e 61 6c 20 74 79 70 65 |he termi|nal type|
|000041d0| 20 61 75 74 6f 6d 61 74 | 69 63 61 6c 6c 79 20 2a | automat|ically *|
|000041e0| 2f 0d 09 09 47 65 74 44 | 49 74 65 6d 28 6e 6d 64 |/...GetD|Item(nmd|
|000041f0| 70 74 72 2c 20 4e 4d 5f | 45 4d 41 55 54 4f 4d 41 |ptr, NM_|EMAUTOMA|
|00004200| 54 49 43 2c 20 26 74 79 | 70 65 2c 20 26 68 69 74 |TIC, &ty|pe, &hit|
|00004210| 65 6d 2c 20 26 72 65 63 | 74 29 3b 0d 09 7d 0d 09 |em, &rec|t);..}..|
|00004220| 65 6c 73 65 20 7b 0d 09 | 09 47 65 74 44 49 74 65 |else {..|.GetDIte|
|00004230| 6d 28 6e 6d 64 70 74 72 | 2c 20 66 69 72 73 74 74 |m(nmdptr|, firstt|
|00004240| 65 72 6d 2c 20 26 74 79 | 70 65 2c 20 26 68 69 74 |erm, &ty|pe, &hit|
|00004250| 65 6d 2c 20 26 72 65 63 | 74 29 3b 0d 09 7d 0d 09 |em, &rec|t);..}..|
|00004260| 2f 2a 20 73 65 74 20 74 | 68 65 20 74 65 72 6d 69 |/* set t|he termi|
|00004270| 6e 61 6c 20 74 79 70 65 | 20 72 61 64 69 6f 20 62 |nal type| radio b|
|00004280| 75 74 74 6f 6e 20 6f 6e | 20 2a 2f 0d 09 53 65 74 |utton on| */..Set|
|00004290| 43 74 6c 56 61 6c 75 65 | 28 68 69 74 65 6d 2c 20 |CtlValue|(hitem, |
|000042a0| 31 29 3b 0d 09 0d 09 54 | 45 46 72 6f 6d 53 63 72 |1);....T|EFromScr|
|000042b0| 61 70 28 29 3b 0d 0d 09 | 77 68 69 6c 65 20 28 31 |ap();...|while (1|
|000042c0| 29 0d 09 7b 0d 09 09 4d | 6f 64 61 6c 44 69 61 6c |)..{...M|odalDial|
|000042d0| 6f 67 28 28 50 72 6f 63 | 50 74 72 29 20 6e 6d 77 |og((Proc|Ptr) nmw|
|000042e0| 69 6e 64 6f 77 66 69 6c | 74 65 72 2c 20 26 69 74 |indowfil|ter, &it|
|000042f0| 65 6d 5f 69 64 29 3b 0d | 09 09 74 65 72 6d 69 6e |em_id);.|..termin|
|00004300| 64 65 78 20 3d 20 69 74 | 65 6d 5f 69 64 20 2d 20 |dex = it|em_id - |
|00004310| 4e 4d 5f 56 54 31 30 30 | 3b 0d 09 09 73 77 69 74 |NM_VT100|;...swit|
|00004320| 63 68 20 28 69 74 65 6d | 5f 69 64 29 0d 09 09 7b |ch (item|_id)...{|
|00004330| 0d 09 09 09 63 61 73 65 | 20 4f 4b 42 3a 20 7b 0d |....case| OKB: {.|
|00004340| 09 09 09 09 66 6f 72 20 | 28 63 6f 75 6e 74 20 3d |....for |(count =|
|00004350| 20 30 3b 20 63 6f 75 6e | 74 20 3c 20 54 45 52 4d | 0; coun|t < TERM|
|00004360| 54 59 50 45 43 4f 55 4e | 54 3b 20 63 6f 75 6e 74 |TYPECOUN|T; count|
|00004370| 2b 2b 29 20 7b 0d 09 09 | 09 09 09 69 66 20 28 21 |++) {...|...if (!|
|00004380| 65 6d 64 70 2d 3e 64 69 | 73 61 62 6c 65 74 65 72 |emdp->di|sableter|
|00004390| 6d 5b 63 6f 75 6e 74 5d | 29 0d 09 09 09 09 09 09 |m[count]|).......|
|000043a0| 62 72 65 61 6b 3b 0d 09 | 09 09 09 7d 0d 09 09 09 |break;..|...}....|
|000043b0| 09 69 66 20 28 63 6f 75 | 6e 74 20 3d 3d 20 54 45 |.if (cou|nt == TE|
|000043c0| 52 4d 54 59 50 45 43 4f | 55 4e 54 29 20 7b 0d 09 |RMTYPECO|UNT) {..|
|000043d0| 09 09 09 09 65 72 72 6f | 72 28 22 53 6f 72 72 79 |....erro|r("Sorry|
|000043e0| 2c 20 62 75 74 20 79 6f | 75 20 6d 75 73 74 20 65 |, but yo|u must e|
|000043f0| 6e 61 62 6c 65 20 61 74 | 20 6c 65 61 73 74 20 6f |nable at| least o|
|00004400| 6e 65 20 74 65 72 6d 69 | 6e 61 6c 20 74 79 70 65 |ne termi|nal type|
|00004410| 21 22 29 3b 0d 09 09 09 | 09 09 62 75 74 68 69 6c |!");....|..buthil|
|00004420| 69 74 65 28 26 6f 6b 72 | 65 63 74 29 3b 0d 09 09 |ite(&okr|ect);...|
|00004430| 09 09 09 62 72 65 61 6b | 3b 0d 09 09 09 09 7d 0d |...break|;.....}.|
|00004440| 0d 09 09 09 09 47 65 74 | 49 54 65 78 74 28 68 6e |.....Get|IText(hn|
|00004450| 61 6d 65 2c 20 26 73 74 | 72 68 6f 73 74 6e 61 6d |ame, &st|rhostnam|
|00004460| 65 29 3b 0d 09 09 09 09 | 0d 09 09 09 09 69 66 20 |e);.....|.....if |
|00004470| 28 74 65 6d 70 63 6f 6e | 6e 74 79 70 65 20 3d 3d |(tempcon|ntype ==|
|00004480| 20 43 4f 4e 4e 5f 4d 41 | 43 54 43 50 29 20 7b 0d | CONN_MA|CTCP) {.|
|00004490| 09 09 09 09 09 2f 2a 20 | 64 69 73 63 72 69 6d 69 |...../* |discrimi|
|000044a0| 6e 61 74 65 20 62 65 74 | 77 65 65 6e 20 74 68 65 |nate bet|ween the|
|000044b0| 20 54 43 50 73 20 2a 2f | 0d 09 09 09 09 09 69 66 | TCPs */|......if|
|000044c0| 20 28 6e 6d 63 75 74 63 | 70 29 0d 09 09 09 09 09 | (nmcutc|p)......|
|000044d0| 09 65 6d 64 70 2d 3e 63 | 6f 6e 6e 74 79 70 65 20 |.emdp->c|onntype |
|000044e0| 3d 20 43 4f 4e 4e 5f 43 | 55 54 43 50 3b 0d 09 09 |= CONN_C|UTCP;...|
|000044f0| 09 09 09 65 6c 73 65 0d | 09 09 09 09 09 09 65 6d |...else.|......em|
|00004500| 64 70 2d 3e 63 6f 6e 6e | 74 79 70 65 20 3d 20 43 |dp->conn|type = C|
|00004510| 4f 4e 4e 5f 4d 41 43 54 | 43 50 3b 0d 09 09 09 09 |ONN_MACT|CP;.....|
|00004520| 7d 0d 09 09 09 09 65 6c | 73 65 0d 09 09 09 09 09 |}.....el|se......|
|00004530| 65 6d 64 70 2d 3e 63 6f | 6e 6e 74 79 70 65 20 3d |emdp->co|nntype =|
|00004540| 20 74 65 6d 70 63 6f 6e | 6e 74 79 70 65 3b 0d 09 | tempcon|ntype;..|
|00004550| 09 09 09 09 0d 09 09 09 | 09 69 66 20 28 6d 61 63 |........|.if (mac|
|00004560| 69 70 6f 70 65 6e 20 0d | 09 09 09 09 09 09 26 26 |ipopen .|......&&|
|00004570| 20 74 65 6d 70 63 6f 6e | 6e 74 79 70 65 20 21 3d | tempcon|ntype !=|
|00004580| 20 43 4f 4e 4e 5f 4d 41 | 43 54 43 50 20 0d 09 09 | CONN_MA|CTCP ...|
|00004590| 09 09 09 09 26 26 20 65 | 6d 64 70 2d 3e 74 63 70 |....&& e|mdp->tcp|
|000045a0| 5f 73 74 72 65 61 6d 29 | 20 0d 09 09 09 09 7b 0d |_stream)| .....{.|
|000045b0| 09 09 09 09 09 2f 2a 20 | 4d 61 63 54 43 50 20 77 |...../* |MacTCP w|
|000045c0| 61 73 20 6f 70 65 6e 20 | 66 6f 72 20 74 68 69 73 |as open |for this|
|000045d0| 20 77 69 6e 64 6f 77 20 | 2a 2f 0d 09 09 09 09 09 | window |*/......|
|000045e0| 69 66 20 28 65 6d 64 70 | 2d 3e 63 6f 6e 6e 6f 70 |if (emdp|->connop|
|000045f0| 65 6e 29 20 7b 0d 09 65 | 72 72 6f 72 28 22 59 6f |en) {..e|rror("Yo|
|00004600| 75 20 6e 65 65 64 20 74 | 6f 20 63 6c 6f 73 65 20 |u need t|o close |
|00004610| 74 68 65 20 6f 70 65 6e | 20 73 65 73 73 69 6f 6e |the open| session|
|00004620| 20 62 65 66 6f 72 65 20 | 73 77 69 74 63 68 69 6e | before |switchin|
|00004630| 67 20 66 72 6f 6d 20 4d | 61 63 54 43 50 22 29 3b |g from M|acTCP");|
|00004640| 0d 09 09 09 09 09 09 62 | 72 65 61 6b 3b 0d 09 09 |.......b|reak;...|
|00004650| 09 09 09 7d 0d 09 09 09 | 09 09 65 6c 73 65 20 7b |...}....|..else {|
|00004660| 0d 09 09 09 09 09 09 2f | 2a 20 72 65 6c 65 61 73 |......./|* releas|
|00004670| 65 20 4d 61 63 54 43 50 | 20 6d 65 6d 6f 72 79 20 |e MacTCP| memory |
|00004680| 2a 2f 0d 09 09 09 09 09 | 09 74 63 70 5f 72 65 6c |*/......|.tcp_rel|
|00004690| 65 61 73 65 28 65 6d 64 | 70 29 3b 0d 09 09 09 09 |ease(emd|p);.....|
|000046a0| 09 09 74 63 70 6d 65 6d | 6f 72 79 72 65 63 6c 61 |..tcpmem|oryrecla|
|000046b0| 69 6d 28 65 6d 64 70 29 | 3b 0d 09 09 09 09 09 7d |im(emdp)|;......}|
|000046c0| 0d 09 09 09 09 7d 0d 0d | 09 09 09 09 2f 2a 20 63 |.....}..|..../* c|
|000046d0| 68 65 63 6b 20 74 6f 20 | 73 65 65 20 77 68 65 74 |heck to |see whet|
|000046e0| 68 65 72 20 74 68 65 20 | 54 43 50 20 70 61 63 6b |her the |TCP pack|
|000046f0| 61 67 65 20 75 73 65 64 | 20 73 68 6f 75 6c 64 20 |age used| should |
|00004700| 63 68 61 6e 67 65 20 2a | 2f 0d 09 09 09 09 69 66 |change *|/.....if|
|00004710| 20 28 6d 61 63 69 70 6f | 70 65 6e 29 20 7b 0d 09 | (macipo|pen) {..|
|00004720| 09 09 09 09 69 66 20 28 | 65 6d 64 70 2d 3e 63 6f |....if (|emdp->co|
|00004730| 6e 6e 74 79 70 65 20 3d | 3d 20 43 4f 4e 4e 5f 43 |nntype =|= CONN_C|
|00004740| 55 54 43 50 29 20 7b 0d | 09 09 09 09 09 09 65 72 |UTCP) {.|......er|
|00004750| 72 6f 72 28 22 4f 70 65 | 6e 69 6e 67 20 73 65 73 |ror("Ope|ning ses|
|00004760| 73 69 6f 6e 20 75 73 69 | 6e 67 20 4d 61 63 54 43 |sion usi|ng MacTC|
|00004770| 50 2c 20 77 68 69 63 68 | 20 69 73 20 61 6c 72 65 |P, which| is alre|
|00004780| 61 64 79 20 72 75 6e 6e | 69 6e 67 22 29 3b 0d 09 |ady runn|ing");..|
|00004790| 09 09 09 09 09 65 6d 64 | 70 2d 3e 63 6f 6e 6e 74 |.....emd|p->connt|
|000047a0| 79 70 65 20 3d 20 43 4f | 4e 4e 5f 4d 41 43 54 43 |ype = CO|NN_MACTC|
|000047b0| 50 3b 0d 09 09 09 09 09 | 7d 0d 09 09 09 09 7d 0d |P;......|}.....}.|
|000047c0| 09 09 09 09 65 6c 73 65 | 20 69 66 20 28 63 75 74 |....else| if (cut|
|000047d0| 63 70 6f 70 65 6e 29 20 | 7b 0d 09 09 09 09 09 69 |cpopen) |{......i|
|000047e0| 66 20 28 65 6d 64 70 2d | 3e 63 6f 6e 6e 74 79 70 |f (emdp-|>conntyp|
|000047f0| 65 20 3d 3d 20 43 4f 4e | 4e 5f 4d 41 43 54 43 50 |e == CON|N_MACTCP|
|00004800| 29 20 7b 0d 09 09 09 09 | 09 09 65 72 72 6f 72 28 |) {.....|..error(|
|00004810| 22 4f 70 65 6e 69 6e 67 | 20 73 65 73 73 69 6f 6e |"Opening| session|
|00004820| 20 75 73 69 6e 67 20 43 | 6f 72 6e 65 6c 6c 20 54 | using C|ornell T|
|00004830| 43 50 2c 20 77 68 69 63 | 68 20 69 73 20 61 6c 72 |CP, whic|h is alr|
|00004840| 65 61 64 79 20 72 75 6e | 6e 69 6e 67 22 29 3b 0d |eady run|ning");.|
|00004850| 09 09 09 09 09 09 65 6d | 64 70 2d 3e 63 6f 6e 6e |......em|dp->conn|
|00004860| 74 79 70 65 20 3d 20 43 | 4f 4e 4e 5f 43 55 54 43 |type = C|ONN_CUTC|
|00004870| 50 3b 0d 09 09 09 09 09 | 7d 0d 09 09 09 09 7d 0d |P;......|}.....}.|
|00004880| 09 09 09 09 0d 09 09 09 | 09 69 66 20 28 65 6d 64 |........|.if (emd|
|00004890| 70 2d 3e 63 6f 6e 6e 74 | 79 70 65 20 3d 3d 20 43 |p->connt|ype == C|
|000048a0| 4f 4e 4e 5f 4d 41 43 54 | 43 50 0d 09 09 09 09 09 |ONN_MACT|CP......|
|000048b0| 09 7c 7c 20 65 6d 64 70 | 2d 3e 63 6f 6e 6e 74 79 |.|| emdp|->connty|
|000048c0| 70 65 20 3d 3d 20 43 4f | 4e 4e 5f 43 55 54 43 50 |pe == CO|NN_CUTCP|
|000048d0| 29 20 7b 0d 09 09 09 09 | 09 2f 2a 20 75 73 65 20 |) {.....|./* use |
|000048e0| 74 68 65 20 68 6f 73 74 | 20 6e 61 6d 65 20 65 6e |the host| name en|
|000048f0| 74 72 79 20 2a 2f 0d 09 | 09 09 09 09 47 65 74 49 |try */..|....GetI|
|00004900| 54 65 78 74 28 68 61 64 | 64 72 2c 20 26 73 74 72 |Text(had|dr, &str|
|00004910| 68 6f 73 74 61 64 64 72 | 29 3b 0d 09 09 09 09 09 |hostaddr|);......|
|00004920| 6c 65 6e 20 3d 20 73 74 | 72 68 6f 73 74 61 64 64 |len = st|rhostadd|
|00004930| 72 2e 6c 65 6e 67 74 68 | 20 2b 20 31 3b 0d 09 09 |r.length| + 1;...|
|00004940| 09 09 09 70 74 6f 63 28 | 26 73 74 72 68 6f 73 74 |...ptoc(|&strhost|
|00004950| 61 64 64 72 29 3b 0d 09 | 09 09 09 09 0d 09 09 09 |addr);..|........|
|00004960| 09 09 47 65 74 49 54 65 | 78 74 28 68 61 64 64 72 |..GetITe|xt(haddr|
|00004970| 74 69 74 2c 20 26 73 74 | 72 68 6f 73 74 61 64 64 |tit, &st|rhostadd|
|00004980| 72 74 69 74 29 3b 0d 09 | 09 09 09 09 53 65 74 49 |rtit);..|....SetI|
|00004990| 54 65 78 74 28 68 61 64 | 64 72 74 69 74 2c 20 22 |Text(had|drtit, "|
|000049a0| 5c 50 52 65 73 6f 6c 76 | 69 6e 67 2e 2e 2e 22 29 |\PResolv|ing...")|
|000049b0| 3b 0d 09 09 09 09 09 0d | 09 09 09 09 09 69 66 20 |;.......|.....if |
|000049c0| 28 72 65 73 6f 6c 76 65 | 5f 6e 61 6d 65 28 26 73 |(resolve|_name(&s|
|000049d0| 74 72 68 6f 73 74 61 64 | 64 72 2c 20 26 65 6d 64 |trhostad|dr, &emd|
|000049e0| 70 2d 3e 66 68 6f 73 74 | 29 29 20 7b 0d 09 09 09 |p->fhost|)) {....|
|000049f0| 09 09 09 2f 2a 20 65 72 | 72 6f 72 20 6f 63 63 75 |.../* er|ror occu|
|00004a00| 72 72 65 64 2c 20 74 68 | 65 20 74 69 74 6c 65 20 |rred, th|e title |
|00004a10| 74 6f 20 22 48 6f 73 74 | 20 61 64 64 72 65 73 73 |to "Host| address|
|00004a20| 22 20 2a 2f 0d 09 09 09 | 09 09 09 53 65 74 49 54 |" */....|...SetIT|
|00004a30| 65 78 74 28 68 61 64 64 | 72 74 69 74 2c 20 26 73 |ext(hadd|rtit, &s|
|00004a40| 74 72 68 6f 73 74 61 64 | 64 72 74 69 74 29 3b 0d |trhostad|drtit);.|
|00004a50| 09 09 09 09 09 09 62 72 | 65 61 6b 3b 0d 09 09 09 |......br|eak;....|
|00004a60| 09 09 7d 0d 0d 09 09 09 | 09 09 69 66 20 28 65 6d |..}.....|..if (em|
|00004a70| 64 70 2d 3e 68 6c 61 73 | 74 68 6f 73 74 29 20 7b |dp->hlas|thost) {|
|00004a80| 0d 09 09 09 09 09 09 44 | 69 73 70 6f 73 48 61 6e |.......D|isposHan|
|00004a90| 64 6c 65 28 65 6d 64 70 | 2d 3e 68 6c 61 73 74 68 |dle(emdp|->hlasth|
|00004aa0| 6f 73 74 29 3b 0d 09 09 | 09 09 09 09 65 6d 64 70 |ost);...|....emdp|
|00004ab0| 2d 3e 68 6c 61 73 74 68 | 6f 73 74 20 3d 20 4e 55 |->hlasth|ost = NU|
|00004ac0| 4c 4c 3b 0d 09 09 09 09 | 09 7d 0d 09 09 09 09 09 |LL;.....|.}......|
|00004ad0| 50 74 72 54 6f 48 61 6e | 64 28 26 73 74 72 68 6f |PtrToHan|d(&strho|
|00004ae0| 73 74 61 64 64 72 2c 20 | 26 65 6d 64 70 2d 3e 68 |staddr, |&emdp->h|
|00004af0| 6c 61 73 74 68 6f 73 74 | 2c 20 28 6c 6f 6e 67 29 |lasthost|, (long)|
|00004b00| 20 6c 65 6e 29 3b 0d 09 | 09 09 09 09 09 2f 2a 20 | len);..|...../* |
|00004b10| 73 61 76 65 20 61 64 64 | 72 65 73 73 20 61 73 20 |save add|ress as |
|00004b20| 63 20 73 74 72 69 6e 67 | 20 69 6e 20 65 6d 64 70 |c string| in emdp|
|00004b30| 2d 3e 68 6c 61 73 74 68 | 6f 73 74 20 2a 2f 0d 0d |->hlasth|ost */..|
|00004b40| 09 09 09 09 7d 0d 09 09 | 09 0d 09 09 09 09 6c 65 |....}...|......le|
|00004b50| 6e 20 3d 20 73 74 72 68 | 6f 73 74 6e 61 6d 65 2e |n = strh|ostname.|
|00004b60| 6c 65 6e 67 74 68 20 2b | 20 31 3b 0d 09 09 09 09 |length +| 1;.....|
|00004b70| 69 66 20 28 65 6d 64 70 | 2d 3e 68 68 6f 73 74 6e |if (emdp|->hhostn|
|00004b80| 61 6d 65 29 20 7b 0d 09 | 09 09 09 09 44 69 73 70 |ame) {..|....Disp|
|00004b90| 6f 73 48 61 6e 64 6c 65 | 28 65 6d 64 70 2d 3e 68 |osHandle|(emdp->h|
|00004ba0| 68 6f 73 74 6e 61 6d 65 | 29 3b 0d 09 09 09 09 09 |hostname|);......|
|00004bb0| 65 6d 64 70 2d 3e 68 68 | 6f 73 74 6e 61 6d 65 20 |emdp->hh|ostname |
|00004bc0| 3d 20 4e 55 4c 4c 3b 0d | 09 09 09 09 7d 0d 09 09 |= NULL;.|....}...|
|00004bd0| 09 09 50 74 72 54 6f 48 | 61 6e 64 28 26 73 74 72 |..PtrToH|and(&str|
|00004be0| 68 6f 73 74 6e 61 6d 65 | 2c 20 26 65 6d 64 70 2d |hostname|, &emdp-|
|00004bf0| 3e 68 68 6f 73 74 6e 61 | 6d 65 2c 20 28 6c 6f 6e |>hhostna|me, (lon|
|00004c00| 67 29 20 6c 65 6e 29 3b | 0d 09 09 09 09 09 2f 2a |g) len);|....../*|
|00004c10| 20 73 61 76 65 20 6e 61 | 6d 65 20 61 73 20 70 61 | save na|me as pa|
|00004c20| 73 63 61 6c 20 73 74 72 | 69 6e 67 20 69 6e 20 65 |scal str|ing in e|
|00004c30| 6d 64 70 2d 3e 68 68 6f | 73 74 6e 61 6d 65 20 2a |mdp->hho|stname *|
|00004c40| 2f 0d 09 09 09 09 73 65 | 74 61 70 70 66 69 6c 65 |/.....se|tappfile|
|00004c50| 6e 61 6d 65 28 29 3b 0d | 09 09 09 09 09 2f 2a 20 |name();.|...../* |
|00004c60| 72 65 73 65 74 20 74 68 | 65 20 64 65 66 61 75 6c |reset th|e defaul|
|00004c70| 74 20 64 6f 63 75 6d 65 | 6e 74 20 66 69 6c 65 20 |t docume|nt file |
|00004c80| 6e 61 6d 65 20 2a 2f 0d | 0d 09 09 09 09 69 66 20 |name */.|.....if |
|00004c90| 28 65 6d 64 70 2d 3e 65 | 6d 77 69 6e 64 6f 77 29 |(emdp->e|mwindow)|
|00004ca0| 20 7b 0d 09 09 09 09 09 | 2f 2a 20 75 70 64 61 74 | {......|/* updat|
|00004cb0| 65 20 74 68 65 20 77 69 | 6e 64 6f 77 20 74 69 74 |e the wi|ndow tit|
|00004cc0| 6c 65 20 69 66 20 61 20 | 77 69 6e 64 6f 77 20 65 |le if a |window e|
|00004cd0| 78 69 73 74 73 20 2a 2f | 0d 09 09 09 09 09 48 4c |xists */|......HL|
|00004ce0| 6f 63 6b 28 65 6d 64 70 | 2d 3e 68 68 6f 73 74 6e |ock(emdp|->hhostn|
|00004cf0| 61 6d 65 29 3b 0d 09 09 | 09 09 09 77 69 6e 64 6f |ame);...|...windo|
|00004d00| 77 74 69 74 6c 65 28 65 | 6d 64 70 2c 20 2a 65 6d |wtitle(e|mdp, *em|
|00004d10| 64 70 2d 3e 68 68 6f 73 | 74 6e 61 6d 65 29 3b 0d |dp->hhos|tname);.|
|00004d20| 09 09 09 09 09 48 55 6e | 6c 6f 63 6b 28 65 6d 64 |.....HUn|lock(emd|
|00004d30| 70 2d 3e 68 68 6f 73 74 | 6e 61 6d 65 29 3b 0d 09 |p->hhost|name);..|
|00004d40| 09 09 09 09 77 69 6e 64 | 6d 65 6e 75 74 69 74 6c |....wind|menutitl|
|00004d50| 65 28 65 6d 64 70 29 3b | 0d 09 09 09 09 7d 0d 09 |e(emdp);|.....}..|
|00004d60| 09 09 09 5a 65 72 6f 53 | 63 72 61 70 28 29 3b 0d |...ZeroS|crap();.|
|00004d70| 09 09 09 09 54 45 54 6f | 53 63 72 61 70 28 29 3b |....TETo|Scrap();|
|00004d80| 0d 09 09 09 09 09 2f 2a | 20 63 6f 70 79 20 74 68 |....../*| copy th|
|00004d90| 65 20 54 45 20 73 63 72 | 61 70 20 74 6f 20 74 68 |e TE scr|ap to th|
|00004da0| 65 20 53 63 72 61 70 20 | 2a 2f 0d 0d 09 09 09 09 |e Scrap |*/......|
|00004db0| 44 69 73 70 6f 73 44 69 | 61 6c 6f 67 28 6e 6d 64 |DisposDi|alog(nmd|
|00004dc0| 70 74 72 29 3b 0d 09 09 | 09 09 53 65 74 50 6f 72 |ptr);...|..SetPor|
|00004dd0| 74 28 6f 70 6f 72 74 29 | 3b 0d 09 09 09 09 6d 6f |t(oport)|;.....mo|
|00004de0| 64 61 6c 64 69 61 6c 6f | 67 20 3d 20 46 41 4c 53 |daldialo|g = FALS|
|00004df0| 45 3b 0d 09 09 09 09 0d | 09 09 09 09 6f 6b 72 65 |E;......|....okre|
|00004e00| 63 74 2e 74 6f 70 20 3d | 20 6f 6b 72 65 63 74 2e |ct.top =| okrect.|
|00004e10| 6c 65 66 74 20 3d 20 6f | 6b 72 65 63 74 2e 62 6f |left = o|krect.bo|
|00004e20| 74 74 6f 6d 20 3d 20 6f | 6b 72 65 63 74 2e 72 69 |ttom = o|krect.ri|
|00004e30| 67 68 74 20 3d 20 30 3b | 0d 09 09 09 09 72 65 74 |ght = 0;|.....ret|
|00004e40| 75 72 6e 28 30 29 3b 0d | 09 09 09 7d 0d 09 09 09 |urn(0);.|...}....|
|00004e50| 63 61 73 65 20 43 41 4e | 42 3a 20 7b 0d 09 09 09 |case CAN|B: {....|
|00004e60| 09 2f 2a 20 72 65 73 74 | 6f 72 65 20 74 68 65 20 |./* rest|ore the |
|00004e70| 6f 6c 64 20 73 65 74 74 | 69 6e 67 73 20 2a 2f 0d |old sett|ings */.|
|00004e80| 09 09 09 09 66 6f 72 20 | 28 63 6f 75 6e 74 20 3d |....for |(count =|
|00004e90| 20 30 3b 20 63 6f 75 6e | 74 20 3c 20 54 45 52 4d | 0; coun|t < TERM|
|00004ea0| 54 59 50 45 43 4f 55 4e | 54 3b 20 63 6f 75 6e 74 |TYPECOUN|T; count|
|00004eb0| 2b 2b 29 20 7b 0d 09 09 | 09 09 09 65 6d 64 70 2d |++) {...|...emdp-|
|00004ec0| 3e 64 69 73 61 62 6c 65 | 74 65 72 6d 5b 63 6f 75 |>disable|term[cou|
|00004ed0| 6e 74 5d 20 3d 20 6f 64 | 69 73 61 62 6c 65 74 65 |nt] = od|isablete|
|00004ee0| 72 6d 5b 63 6f 75 6e 74 | 5d 3b 0d 09 09 09 09 7d |rm[count|];.....}|
|00004ef0| 0d 09 09 09 09 65 6d 64 | 70 2d 3e 69 62 6d 5f 6b |.....emd|p->ibm_k|
|00004f00| 65 79 6d 6f 64 65 20 3d | 20 6f 69 62 6d 6b 65 79 |eymode =| oibmkey|
|00004f10| 3b 0d 09 09 09 09 65 6d | 64 70 2d 3e 63 6f 6e 66 |;.....em|dp->conf|
|00004f20| 63 68 61 6e 67 65 64 20 | 3d 20 46 41 4c 53 45 3b |changed |= FALSE;|
|00004f30| 0d 09 09 09 09 65 6d 64 | 70 2d 3e 6e 65 77 63 6f |.....emd|p->newco|
|00004f40| 6e 66 20 3d 20 6f 6e 65 | 77 63 6f 6e 66 3b 0d 0d |nf = one|wconf;..|
|00004f50| 09 09 09 09 5a 65 72 6f | 53 63 72 61 70 28 29 3b |....Zero|Scrap();|
|00004f60| 0d 09 09 09 09 54 45 54 | 6f 53 63 72 61 70 28 29 |.....TET|oScrap()|
|00004f70| 3b 0d 09 09 09 09 09 2f | 2a 20 63 6f 70 79 20 74 |;....../|* copy t|
|00004f80| 68 65 20 54 45 20 73 63 | 72 61 70 20 74 6f 20 74 |he TE sc|rap to t|
|00004f90| 68 65 20 53 63 72 61 70 | 20 2a 2f 0d 0d 09 09 09 |he Scrap| */.....|
|00004fa0| 09 44 69 73 70 6f 73 44 | 69 61 6c 6f 67 28 6e 6d |.DisposD|ialog(nm|
|00004fb0| 64 70 74 72 29 3b 0d 09 | 09 09 09 53 65 74 50 6f |dptr);..|...SetPo|
|00004fc0| 72 74 28 6f 70 6f 72 74 | 29 3b 0d 09 09 09 09 6d |rt(oport|);.....m|
|00004fd0| 6f 64 61 6c 64 69 61 6c | 6f 67 20 3d 20 46 41 4c |odaldial|og = FAL|
|00004fe0| 53 45 3b 0d 0d 09 09 09 | 09 6f 6b 72 65 63 74 2e |SE;.....|.okrect.|
|00004ff0| 74 6f 70 20 3d 20 6f 6b | 72 65 63 74 2e 6c 65 66 |top = ok|rect.lef|
|00005000| 74 20 3d 20 6f 6b 72 65 | 63 74 2e 62 6f 74 74 6f |t = okre|ct.botto|
|00005010| 6d 20 3d 20 6f 6b 72 65 | 63 74 2e 72 69 67 68 74 |m = okre|ct.right|
|00005020| 20 3d 20 30 3b 0d 09 09 | 09 09 72 65 74 75 72 6e | = 0;...|..return|
|00005030| 28 2d 31 29 3b 0d 09 09 | 09 7d 0d 09 09 09 63 61 |(-1);...|.}....ca|
|00005040| 73 65 20 4e 4d 5f 48 4f | 53 54 41 44 44 52 3a 20 |se NM_HO|STADDR: |
|00005050| 7b 0d 09 09 09 09 65 6d | 64 70 2d 3e 63 6f 6e 66 |{.....em|dp->conf|
|00005060| 63 68 61 6e 67 65 64 20 | 3d 20 54 52 55 45 3b 0d |changed |= TRUE;.|
|00005070| 09 09 09 09 62 72 65 61 | 6b 3b 0d 09 09 09 7d 0d |....brea|k;....}.|
|00005080| 09 09 09 63 61 73 65 20 | 4e 4d 5f 48 4f 53 54 4e |...case |NM_HOSTN|
|00005090| 41 4d 45 3a 20 7b 0d 09 | 09 09 09 65 6d 64 70 2d |AME: {..|...emdp-|
|000050a0| 3e 63 6f 6e 66 63 68 61 | 6e 67 65 64 20 3d 20 54 |>confcha|nged = T|
|000050b0| 52 55 45 3b 0d 09 09 09 | 09 65 6d 64 70 2d 3e 6e |RUE;....|.emdp->n|
|000050c0| 65 77 63 6f 6e 66 20 3d | 20 54 52 55 45 3b 0d 09 |ewconf =| TRUE;..|
|000050d0| 09 09 09 62 72 65 61 6b | 3b 0d 09 09 09 7d 0d 09 |...break|;....}..|
|000050e0| 09 09 2f 2a 20 63 6f 6e | 6e 65 63 74 69 6f 6e 20 |../* con|nection |
|000050f0| 74 79 70 65 73 20 2d 2d | 20 34 20 72 61 64 69 6f |types --| 4 radio|
|00005100| 20 62 75 74 74 6f 6e 73 | 20 2a 2f 0d 09 09 09 63 | buttons| */....c|
|00005110| 61 73 65 20 4e 4d 5f 43 | 4f 4e 4e 3a 20 7b 0d 09 |ase NM_C|ONN: {..|
|00005120| 09 09 09 6e 6d 64 69 61 | 6c 62 75 74 73 65 74 28 |...nmdia|lbutset(|
|00005130| 6e 6d 64 70 74 72 2c 20 | 69 74 65 6d 5f 69 64 29 |nmdptr, |item_id)|
|00005140| 3b 0d 09 09 09 09 6e 6d | 73 65 74 74 63 70 28 6e |;.....nm|settcp(n|
|00005150| 6d 64 70 74 72 2c 20 46 | 41 4c 53 45 29 3b 0d 09 |mdptr, F|ALSE);..|
|00005160| 09 09 09 74 65 6d 70 63 | 6f 6e 6e 74 79 70 65 20 |...tempc|onntype |
|00005170| 3d 20 43 4f 4e 4e 5f 43 | 4f 4d 4d 4d 47 52 3b 0d |= CONN_C|OMMMGR;.|
|00005180| 09 09 09 09 62 72 65 61 | 6b 3b 0d 09 09 09 7d 0d |....brea|k;....}.|
|00005190| 09 09 09 63 61 73 65 20 | 4e 4d 5f 53 45 52 44 41 |...case |NM_SERDA|
|000051a0| 3a 20 7b 0d 09 09 09 09 | 6e 6d 64 69 61 6c 62 75 |: {.....|nmdialbu|
|000051b0| 74 73 65 74 28 6e 6d 64 | 70 74 72 2c 20 69 74 65 |tset(nmd|ptr, ite|
|000051c0| 6d 5f 69 64 29 3b 0d 09 | 09 09 09 6e 6d 73 65 74 |m_id);..|...nmset|
|000051d0| 74 63 70 28 6e 6d 64 70 | 74 72 2c 20 46 41 4c 53 |tcp(nmdp|tr, FALS|
|000051e0| 45 29 3b 0d 09 09 09 09 | 74 65 6d 70 63 6f 6e 6e |E);.....|tempconn|
|000051f0| 74 79 70 65 20 3d 20 43 | 4f 4e 4e 5f 53 45 52 44 |type = C|ONN_SERD|
|00005200| 3b 0d 09 09 09 09 65 6d | 64 70 2d 3e 75 73 65 62 |;.....em|dp->useb|
|00005210| 70 6f 72 74 20 3d 20 46 | 41 4c 53 45 3b 0d 09 09 |port = F|ALSE;...|
|00005220| 09 09 62 72 65 61 6b 3b | 0d 09 09 09 7d 0d 09 09 |..break;|....}...|
|00005230| 09 63 61 73 65 20 4e 4d | 5f 53 45 52 44 42 3a 20 |.case NM|_SERDB: |
|00005240| 7b 0d 09 09 09 09 6e 6d | 64 69 61 6c 62 75 74 73 |{.....nm|dialbuts|
|00005250| 65 74 28 6e 6d 64 70 74 | 72 2c 20 69 74 65 6d 5f |et(nmdpt|r, item_|
|00005260| 69 64 29 3b 0d 09 09 09 | 09 6e 6d 73 65 74 74 63 |id);....|.nmsettc|
|00005270| 70 28 6e 6d 64 70 74 72 | 2c 20 46 41 4c 53 45 29 |p(nmdptr|, FALSE)|
|00005280| 3b 0d 09 09 09 09 74 65 | 6d 70 63 6f 6e 6e 74 79 |;.....te|mpconnty|
|00005290| 70 65 20 3d 20 43 4f 4e | 4e 5f 53 45 52 44 3b 0d |pe = CON|N_SERD;.|
|000052a0| 09 09 09 09 65 6d 64 70 | 2d 3e 75 73 65 62 70 6f |....emdp|->usebpo|
|000052b0| 72 74 20 3d 20 54 52 55 | 45 3b 0d 09 09 09 09 62 |rt = TRU|E;.....b|
|000052c0| 72 65 61 6b 3b 0d 09 09 | 09 7d 0d 09 09 09 63 61 |reak;...|.}....ca|
|000052d0| 73 65 20 4e 4d 5f 54 43 | 50 3a 20 7b 0d 09 09 09 |se NM_TC|P: {....|
|000052e0| 09 2f 2a 20 73 65 6c 65 | 63 74 20 54 43 50 20 2a |./* sele|ct TCP *|
|000052f0| 2f 0d 09 09 09 09 6e 6d | 64 69 61 6c 62 75 74 73 |/.....nm|dialbuts|
|00005300| 65 74 28 6e 6d 64 70 74 | 72 2c 20 69 74 65 6d 5f |et(nmdpt|r, item_|
|00005310| 69 64 29 3b 0d 09 09 09 | 09 6e 6d 73 65 74 74 63 |id);....|.nmsettc|
|00005320| 70 28 6e 6d 64 70 74 72 | 2c 20 54 52 55 45 29 3b |p(nmdptr|, TRUE);|
|00005330| 0d 09 09 09 09 74 65 6d | 70 63 6f 6e 6e 74 79 70 |.....tem|pconntyp|
|00005340| 65 20 3d 20 43 4f 4e 4e | 5f 4d 41 43 54 43 50 3b |e = CONN|_MACTCP;|
|00005350| 0d 09 09 09 09 62 72 65 | 61 6b 3b 0d 09 09 09 7d |.....bre|ak;....}|
|00005360| 0d 23 69 66 64 65 66 20 | 44 55 41 4c 54 43 50 0d |.#ifdef |DUALTCP.|
|00005370| 09 09 09 63 61 73 65 20 | 4e 4d 5f 43 55 54 43 50 |...case |NM_CUTCP|
|00005380| 3a 20 7b 0d 09 09 09 09 | 2f 2a 20 73 77 69 74 63 |: {.....|/* switc|
|00005390| 68 20 62 65 74 77 65 65 | 6e 20 4d 61 63 54 43 50 |h betwee|n MacTCP|
|000053a0| 20 26 20 63 6f 72 6e 65 | 6c 6c 20 2a 2f 0d 09 09 | & corne|ll */...|
|000053b0| 09 09 2f 2a 20 79 6f 75 | 20 63 61 6e 27 74 20 63 |../* you| can't c|
|000053c0| 68 61 6e 67 65 20 74 72 | 61 6e 73 70 6f 72 74 20 |hange tr|ansport |
|000053d0| 68 6f 72 73 65 73 20 69 | 6e 20 6d 69 64 73 74 72 |horses i|n midstr|
|000053e0| 65 61 6d 20 2a 2f 0d 09 | 09 09 09 69 66 20 28 6e |eam */..|...if (n|
|000053f0| 6d 63 75 74 63 70 29 20 | 7b 0d 09 09 09 09 09 09 |mcutcp) |{.......|
|00005400| 6e 6d 63 75 74 63 70 20 | 3d 20 46 41 4c 53 45 3b |nmcutcp |= FALSE;|
|00005410| 0d 09 09 09 09 7d 0d 09 | 09 09 09 65 6c 73 65 0d |.....}..|...else.|
|00005420| 09 09 09 09 09 09 6e 6d | 63 75 74 63 70 20 3d 20 |......nm|cutcp = |
|00005430| 54 52 55 45 3b 0d 0d 09 | 09 09 09 47 65 74 44 49 |TRUE;...|...GetDI|
|00005440| 74 65 6d 28 6e 6d 64 70 | 74 72 2c 20 4e 4d 5f 43 |tem(nmdp|tr, NM_C|
|00005450| 55 54 43 50 2c 20 26 74 | 79 70 65 2c 20 26 68 69 |UTCP, &t|ype, &hi|
|00005460| 74 65 6d 2c 20 26 72 65 | 63 74 29 3b 0d 09 09 09 |tem, &re|ct);....|
|00005470| 09 53 65 74 43 74 6c 56 | 61 6c 75 65 28 68 69 74 |.SetCtlV|alue(hit|
|00005480| 65 6d 2c 20 6e 6d 63 75 | 74 63 70 20 3f 20 30 20 |em, nmcu|tcp ? 0 |
|00005490| 3a 20 31 29 3b 0d 09 09 | 09 09 62 72 65 61 6b 3b |: 1);...|..break;|
|000054a0| 0d 09 09 09 7d 0d 23 65 | 6e 64 69 66 0d 09 09 09 |....}.#e|ndif....|
|000054b0| 2f 2a 20 74 65 72 6d 69 | 6e 61 6c 20 74 79 70 65 |/* termi|nal type|
|000054c0| 73 2c 20 33 20 63 68 65 | 63 6b 20 62 6f 78 65 73 |s, 3 che|ck boxes|
|000054d0| 20 2a 2f 0d 09 09 09 63 | 61 73 65 20 4e 4d 5f 56 | */....c|ase NM_V|
|000054e0| 54 31 30 30 3a 0d 09 09 | 09 63 61 73 65 20 4e 4d |T100:...|.case NM|
|000054f0| 5f 56 54 31 30 32 3a 0d | 09 09 09 63 61 73 65 20 |_VT102:.|...case |
|00005500| 4e 4d 5f 33 32 37 38 3a | 0d 09 09 09 63 61 73 65 |NM_3278:|....case|
|00005510| 20 4e 4d 5f 48 31 39 3a | 0d 09 09 09 63 61 73 65 | NM_H19:|....case|
|00005520| 20 4e 4d 5f 45 4d 41 55 | 54 4f 4d 41 54 49 43 3a | NM_EMAU|TOMATIC:|
|00005530| 0d 09 09 09 7b 0d 09 09 | 09 09 6e 6d 74 65 72 6d |....{...|..nmterm|
|00005540| 62 75 74 73 65 74 28 6e | 6d 64 70 74 72 2c 20 69 |butset(n|mdptr, i|
|00005550| 74 65 6d 5f 69 64 29 3b | 0d 09 09 09 09 62 72 65 |tem_id);|.....bre|
|00005560| 61 6b 3b 0d 09 09 09 7d | 09 09 09 0d 09 09 09 63 |ak;....}|.......c|
|00005570| 61 73 65 20 4e 4d 5f 49 | 42 4d 4b 45 59 3a 20 7b |ase NM_I|BMKEY: {|
|00005580| 0d 09 09 09 09 2f 2a 20 | 55 4e 55 53 45 44 2d 2d |...../* |UNUSED--|
|00005590| 6e 6f 77 20 73 65 74 20 | 69 6e 20 74 68 65 20 43 |now set |in the C|
|000055a0| 6f 6e 74 72 6f 6c 20 57 | 69 6e 64 6f 77 20 64 69 |ontrol W|indow di|
|000055b0| 61 6c 6f 67 20 2a 2f 0d | 09 09 09 09 0d 09 09 09 |alog */.|........|
|000055c0| 09 65 6d 64 70 2d 3e 69 | 62 6d 5f 6b 65 79 6d 6f |.emdp->i|bm_keymo|
|000055d0| 64 65 20 3d 20 21 65 6d | 64 70 2d 3e 69 62 6d 5f |de = !em|dp->ibm_|
|000055e0| 6b 65 79 6d 6f 64 65 3b | 0d 09 09 09 09 65 6d 64 |keymode;|.....emd|
|000055f0| 70 2d 3e 63 6f 6e 66 63 | 68 61 6e 67 65 64 20 3d |p->confc|hanged =|
|00005600| 20 54 52 55 45 3b 0d 09 | 09 09 09 53 65 74 43 74 | TRUE;..|...SetCt|
|00005610| 6c 56 61 6c 75 65 28 68 | 69 62 6d 6b 65 79 2c 20 |lValue(h|ibmkey, |
|00005620| 65 6d 64 70 2d 3e 69 62 | 6d 5f 6b 65 79 6d 6f 64 |emdp->ib|m_keymod|
|00005630| 65 20 3f 20 31 20 3a 20 | 30 29 3b 0d 09 09 09 09 |e ? 1 : |0);.....|
|00005640| 62 72 65 61 6b 3b 0d 09 | 09 09 7d 0d 09 09 09 63 |break;..|..}....c|
|00005650| 61 73 65 20 4e 4d 5f 48 | 45 4c 50 42 55 54 3a 20 |ase NM_H|ELPBUT: |
|00005660| 7b 0d 09 09 09 09 68 65 | 6c 70 77 69 6e 64 6f 77 |{.....he|lpwindow|
|00005670| 28 54 45 58 54 4c 4f 47 | 4f 4e 2c 20 67 65 6e 65 |(TEXTLOG|ON, gene|
|00005680| 76 61 2c 20 39 29 3b 0d | 09 09 09 09 6d 6f 64 61 |va, 9);.|....moda|
|00005690| 6c 64 69 61 6c 6f 67 20 | 3d 20 54 52 55 45 3b 0d |ldialog |= TRUE;.|
|000056a0| 09 09 09 09 62 72 65 61 | 6b 3b 0d 09 09 09 7d 0d |....brea|k;....}.|
|000056b0| 09 09 09 64 65 66 61 75 | 6c 74 3a 20 7b 0d 09 09 |...defau|lt: {...|
|000056c0| 09 09 62 72 65 61 6b 3b | 0d 09 09 09 7d 0d 09 09 |..break;|....}...|
|000056d0| 7d 0d 09 7d 0d 7d 0d 0d | 0d 2f 2a 20 73 65 74 20 |}..}.}..|./* set |
|000056e0| 54 43 50 20 69 74 65 6d | 73 20 6f 6e 20 6f 72 20 |TCP item|s on or |
|000056f0| 6f 66 66 20 2a 2f 0d 0d | 6e 6d 73 65 74 74 63 70 |off */..|nmsettcp|
|00005700| 28 6e 6d 64 70 74 72 2c | 20 73 74 61 74 65 29 0d |(nmdptr,| state).|
|00005710| 44 69 61 6c 6f 67 50 74 | 72 20 6e 6d 64 70 74 72 |DialogPt|r nmdptr|
|00005720| 3b 0d 69 6e 74 20 73 74 | 61 74 65 3b 0d 7b 0d 09 |;.int st|ate;.{..|
|00005730| 48 61 6e 64 6c 65 20 68 | 69 74 65 6d 3b 0d 09 73 |Handle h|item;..s|
|00005740| 68 6f 72 74 09 74 79 70 | 65 3b 0d 09 52 65 63 74 |hort.typ|e;..Rect|
|00005750| 20 72 65 63 74 3b 0d 0d | 23 69 66 64 65 66 20 54 | rect;..|#ifdef T|
|00005760| 43 50 53 45 4c 45 43 54 | 0d 09 69 66 20 28 73 74 |CPSELECT|..if (st|
|00005770| 61 74 65 20 3d 3d 20 69 | 70 61 64 64 72 76 69 73 |ate == i|paddrvis|
|00005780| 29 20 7b 0d 09 09 2f 2a | 20 73 61 6d 65 20 73 74 |) {.../*| same st|
|00005790| 61 74 65 20 61 73 20 62 | 65 66 6f 72 65 2c 20 69 |ate as b|efore, i|
|000057a0| 67 6e 6f 72 65 20 2a 2f | 0d 09 09 72 65 74 75 72 |gnore */|...retur|
|000057b0| 6e 3b 0d 09 7d 0d 09 65 | 6c 73 65 20 7b 0d 09 09 |n;..}..e|lse {...|
|000057c0| 69 70 61 64 64 72 76 69 | 73 20 3d 20 73 74 61 74 |ipaddrvi|s = stat|
|000057d0| 65 3b 0d 09 09 0d 09 09 | 69 66 20 28 69 70 61 64 |e;......|if (ipad|
|000057e0| 64 72 76 69 73 29 20 7b | 0d 09 09 09 47 65 74 44 |drvis) {|....GetD|
|000057f0| 49 74 65 6d 28 6e 6d 64 | 70 74 72 2c 20 4e 4d 5f |Item(nmd|ptr, NM_|
|00005800| 48 4f 53 54 41 44 44 52 | 2c 20 26 74 79 70 65 2c |HOSTADDR|, &type,|
|00005810| 20 26 68 69 74 65 6d 2c | 20 26 72 65 63 74 29 3b | &hitem,| &rect);|
|00005820| 0d 09 09 09 53 65 74 44 | 49 74 65 6d 28 6e 6d 64 |....SetD|Item(nmd|
|00005830| 70 74 72 2c 20 4e 4d 5f | 48 4f 53 54 41 44 44 52 |ptr, NM_|HOSTADDR|
|00005840| 2c 20 65 64 69 74 54 65 | 78 74 2c 20 68 69 74 65 |, editTe|xt, hite|
|00005850| 6d 2c 20 26 72 65 63 74 | 29 3b 0d 0d 09 09 09 47 |m, &rect|);.....G|
|00005860| 65 74 44 49 74 65 6d 28 | 6e 6d 64 70 74 72 2c 20 |etDItem(|nmdptr, |
|00005870| 4e 4d 5f 48 4f 53 54 41 | 44 44 52 54 49 54 2c 20 |NM_HOSTA|DDRTIT, |
|00005880| 26 74 79 70 65 2c 20 26 | 68 69 74 65 6d 2c 20 26 |&type, &|hitem, &|
|00005890| 72 65 63 74 29 3b 0d 09 | 09 09 53 65 74 44 49 74 |rect);..|..SetDIt|
|000058a0| 65 6d 28 6e 6d 64 70 74 | 72 2c 20 4e 4d 5f 48 4f |em(nmdpt|r, NM_HO|
|000058b0| 53 54 41 44 44 52 54 49 | 54 2c 20 73 74 61 74 54 |STADDRTI|T, statT|
|000058c0| 65 78 74 2c 20 68 69 74 | 65 6d 2c 20 26 72 65 63 |ext, hit|em, &rec|
|000058d0| 74 29 3b 0d 0d 09 09 09 | 2f 2a 20 73 77 69 74 63 |t);.....|/* switc|
|000058e0| 68 20 74 6f 20 74 68 65 | 20 61 64 64 72 65 73 73 |h to the| address|
|000058f0| 20 65 64 69 74 69 6e 67 | 20 66 69 65 6c 64 20 20 | editing| field |
|00005900| 2a 2f 0d 09 09 09 53 65 | 6c 49 54 65 78 74 28 6e |*/....Se|lIText(n|
|00005910| 6d 64 70 74 72 2c 20 4e | 4d 5f 48 4f 53 54 4e 41 |mdptr, N|M_HOSTNA|
|00005920| 4d 45 2c 20 30 2c 20 30 | 29 3b 0d 09 09 09 53 65 |ME, 0, 0|);....Se|
|00005930| 6c 49 54 65 78 74 28 6e | 6d 64 70 74 72 2c 20 4e |lIText(n|mdptr, N|
|00005940| 4d 5f 48 4f 53 54 41 44 | 44 52 2c 20 30 2c 20 31 |M_HOSTAD|DR, 0, 1|
|00005950| 30 30 30 29 3b 0d 09 09 | 7d 0d 09 09 65 6c 73 65 |000);...|}...else|
|00005960| 20 7b 0d 09 09 09 69 66 | 20 28 28 28 44 69 61 6c | {....if| (((Dial|
|00005970| 6f 67 50 65 65 6b 29 20 | 6e 6d 64 70 74 72 29 2d |ogPeek) |nmdptr)-|
|00005980| 3e 65 64 69 74 46 69 65 | 6c 64 20 3d 3d 20 4e 4d |>editFie|ld == NM|
|00005990| 5f 48 4f 53 54 41 44 44 | 52 20 2d 20 31 29 20 7b |_HOSTADD|R - 1) {|
|000059a0| 0d 09 09 09 09 2f 2a 20 | 73 77 69 74 63 68 20 74 |...../* |switch t|
|000059b0| 6f 20 74 68 65 20 6e 61 | 6d 65 20 65 64 69 74 69 |o the na|me editi|
|000059c0| 6e 67 20 66 69 65 6c 64 | 20 69 66 20 41 64 64 72 |ng field| if Addr|
|000059d0| 65 73 73 20 69 73 20 74 | 68 65 20 63 75 72 72 65 |ess is t|he curre|
|000059e0| 6e 74 20 66 69 65 6c 64 | 20 2a 2f 0d 09 09 09 09 |nt field| */.....|
|000059f0| 53 65 6c 49 54 65 78 74 | 28 6e 6d 64 70 74 72 2c |SelIText|(nmdptr,|
|00005a00| 20 4e 4d 5f 48 4f 53 54 | 41 44 44 52 2c 20 30 2c | NM_HOST|ADDR, 0,|
|00005a10| 20 30 29 3b 0d 09 09 09 | 09 53 65 6c 49 54 65 78 | 0);....|.SelITex|
|00005a20| 74 28 6e 6d 64 70 74 72 | 2c 20 4e 4d 5f 48 4f 53 |t(nmdptr|, NM_HOS|
|00005a30| 54 4e 41 4d 45 2c 20 30 | 2c 20 31 30 30 30 29 3b |TNAME, 0|, 1000);|
|00005a40| 0d 09 09 09 7d 0d 09 09 | 09 47 65 74 44 49 74 65 |....}...|.GetDIte|
|00005a50| 6d 28 6e 6d 64 70 74 72 | 2c 20 4e 4d 5f 48 4f 53 |m(nmdptr|, NM_HOS|
|00005a60| 54 41 44 44 52 2c 20 26 | 74 79 70 65 2c 20 26 68 |TADDR, &|type, &h|
|00005a70| 69 74 65 6d 2c 20 26 72 | 65 63 74 29 3b 0d 09 09 |item, &r|ect);...|
|00005a80| 09 53 65 74 44 49 74 65 | 6d 28 6e 6d 64 70 74 72 |.SetDIte|m(nmdptr|
|00005a90| 2c 20 4e 4d 5f 48 4f 53 | 54 41 44 44 52 2c 20 65 |, NM_HOS|TADDR, e|
|00005aa0| 64 69 74 54 65 78 74 2c | 20 68 69 74 65 6d 2c 20 |ditText,| hitem, |
|00005ab0| 26 72 65 63 74 29 3b 0d | 09 09 09 09 2f 2a 20 20 |&rect);.|..../* |
|00005ac0| 2b 20 69 74 65 6d 44 69 | 73 61 62 6c 65 2c 20 69 |+ itemDi|sable, i|
|00005ad0| 66 20 6f 6e 6c 79 20 44 | 69 61 6c 6f 67 20 4d 61 |f only D|ialog Ma|
|00005ae0| 6e 61 67 65 72 20 64 69 | 64 20 73 6f 6d 65 74 68 |nager di|d someth|
|00005af0| 69 6e 67 20 75 73 65 66 | 75 6c 2e 2e 2e 20 2a 2f |ing usef|ul... */|
|00005b00| 0d 09 09 09 47 65 74 44 | 49 74 65 6d 28 6e 6d 64 |....GetD|Item(nmd|
|00005b10| 70 74 72 2c 20 4e 4d 5f | 48 4f 53 54 41 44 44 52 |ptr, NM_|HOSTADDR|
|00005b20| 54 49 54 2c 20 26 74 79 | 70 65 2c 20 26 68 69 74 |TIT, &ty|pe, &hit|
|00005b30| 65 6d 2c 20 26 72 65 63 | 74 29 3b 0d 09 09 09 53 |em, &rec|t);....S|
|00005b40| 65 74 44 49 74 65 6d 28 | 6e 6d 64 70 74 72 2c 20 |etDItem(|nmdptr, |
|00005b50| 4e 4d 5f 48 4f 53 54 41 | 44 44 52 54 49 54 2c 20 |NM_HOSTA|DDRTIT, |
|00005b60| 73 74 61 74 54 65 78 74 | 20 2b 20 69 74 65 6d 44 |statText| + itemD|
|00005b70| 69 73 61 62 6c 65 2c 20 | 68 69 74 65 6d 2c 20 26 |isable, |hitem, &|
|00005b80| 72 65 63 74 29 3b 0d 09 | 09 7d 0d 09 7d 0d 23 65 |rect);..|.}..}.#e|
|00005b90| 6c 73 65 0d 09 2f 2a 20 | 64 6f 65 73 6e 27 74 20 |lse../* |doesn't |
|00005ba0| 61 63 74 75 61 6c 6c 79 | 20 64 69 73 61 62 6c 65 |actually| disable|
|00005bb0| 20 74 68 65 20 74 68 69 | 6e 67 20 61 6e 79 77 61 | the thi|ng anywa|
|00005bc0| 79 2e 2e 2e 20 6c 6f 72 | 64 20 74 68 65 20 64 69 |y... lor|d the di|
|00005bd0| 61 6c 6f 67 20 6d 61 6e | 61 67 65 72 20 69 73 0d |alog man|ager is.|
|00005be0| 09 09 75 73 65 6c 65 73 | 73 21 0d 09 47 65 74 44 |..useles|s!..GetD|
|00005bf0| 49 74 65 6d 28 6e 6d 64 | 70 74 72 2c 20 4e 4d 5f |Item(nmd|ptr, NM_|
|00005c00| 48 4f 53 54 41 44 44 52 | 2c 20 26 74 79 70 65 2c |HOSTADDR|, &type,|
|00005c10| 20 26 68 69 74 65 6d 2c | 20 26 72 65 63 74 29 3b | &hitem,| &rect);|
|00005c20| 0d 09 53 65 74 44 49 74 | 65 6d 28 6e 6d 64 70 74 |..SetDIt|em(nmdpt|
|00005c30| 72 2c 20 4e 4d 5f 48 4f | 53 54 41 44 44 52 2c 20 |r, NM_HO|STADDR, |
|00005c40| 74 79 70 65 20 2b 20 73 | 74 61 74 65 2c 20 68 69 |type + s|tate, hi|
|00005c50| 74 65 6d 2c 20 26 72 65 | 63 74 29 3b 0d 09 2a 2f |tem, &re|ct);..*/|
|00005c60| 0d 09 0d 09 47 65 74 44 | 49 74 65 6d 28 6e 6d 64 |....GetD|Item(nmd|
|00005c70| 70 74 72 2c 20 4e 4d 5f | 48 4f 53 54 41 44 44 52 |ptr, NM_|HOSTADDR|
|00005c80| 54 49 54 2c 20 26 74 79 | 70 65 2c 20 26 68 69 74 |TIT, &ty|pe, &hit|
|00005c90| 65 6d 2c 20 26 72 65 63 | 74 29 3b 0d 09 53 65 74 |em, &rec|t);..Set|
|00005ca0| 44 49 74 65 6d 28 6e 6d | 64 70 74 72 2c 20 4e 4d |DItem(nm|dptr, NM|
|00005cb0| 5f 48 4f 53 54 41 44 44 | 52 54 49 54 2c 20 74 79 |_HOSTADD|RTIT, ty|
|00005cc0| 70 65 20 2b 20 73 74 61 | 74 65 2c 20 68 69 74 65 |pe + sta|te, hite|
|00005cd0| 6d 2c 20 26 72 65 63 74 | 29 3b 0d 0d 23 69 66 64 |m, &rect|);..#ifd|
|00005ce0| 65 66 20 44 55 41 4c 54 | 43 50 0d 09 47 65 74 44 |ef DUALT|CP..GetD|
|00005cf0| 49 74 65 6d 28 6e 6d 64 | 70 74 72 2c 20 4e 4d 5f |Item(nmd|ptr, NM_|
|00005d00| 43 55 54 43 50 2c 20 26 | 74 79 70 65 2c 20 26 68 |CUTCP, &|type, &h|
|00005d10| 69 74 65 6d 2c 20 26 72 | 65 63 74 29 3b 0d 09 48 |item, &r|ect);..H|
|00005d20| 69 6c 69 74 65 43 6f 6e | 74 72 6f 6c 28 68 69 74 |iliteCon|trol(hit|
|00005d30| 65 6d 2c 20 73 74 61 74 | 65 20 3f 20 30 20 3a 20 |em, stat|e ? 0 : |
|00005d40| 32 35 35 29 3b 0d 23 65 | 6e 64 69 66 0d 23 65 6e |255);.#e|ndif.#en|
|00005d50| 64 69 66 0d 7d 0d 0d 2f | 2a 20 73 65 74 20 74 68 |dif.}../|* set th|
|00005d60| 65 20 62 75 74 74 6f 6e | 20 73 65 6c 65 63 74 65 |e button| selecte|
|00005d70| 64 20 61 6e 64 20 72 65 | 73 65 74 20 74 68 65 20 |d and re|set the |
|00005d80| 6f 74 68 65 72 73 20 2a | 2f 0d 0d 6e 6d 64 69 61 |others *|/..nmdia|
|00005d90| 6c 62 75 74 73 65 74 28 | 64 6c 6f 67 2c 20 69 74 |lbutset(|dlog, it|
|00005da0| 65 6d 69 64 29 0d 44 69 | 61 6c 6f 67 50 74 72 20 |emid).Di|alogPtr |
|00005db0| 64 6c 6f 67 3b 0d 73 68 | 6f 72 74 20 69 74 65 6d |dlog;.sh|ort item|
|00005dc0| 69 64 3b 0d 7b 0d 09 73 | 68 6f 72 74 09 74 79 70 |id;.{..s|hort.typ|
|00005dd0| 65 3b 0d 09 52 65 63 74 | 20 72 65 63 74 3b 0d 09 |e;..Rect| rect;..|
|00005de0| 48 61 6e 64 6c 65 20 68 | 69 74 65 6d 3b 0d 0d 09 |Handle h|item;...|
|00005df0| 65 6d 64 70 2d 3e 63 6f | 6e 66 63 68 61 6e 67 65 |emdp->co|nfchange|
|00005e00| 64 20 3d 20 54 52 55 45 | 3b 0d 0d 09 47 65 74 44 |d = TRUE|;...GetD|
|00005e10| 49 74 65 6d 28 64 6c 6f | 67 2c 20 4e 4d 5f 43 4f |Item(dlo|g, NM_CO|
|00005e20| 4e 4e 2c 20 26 74 79 70 | 65 2c 20 26 68 69 74 65 |NN, &typ|e, &hite|
|00005e30| 6d 2c 20 26 72 65 63 74 | 29 3b 0d 09 53 65 74 43 |m, &rect|);..SetC|
|00005e40| 74 6c 56 61 6c 75 65 28 | 68 69 74 65 6d 2c 20 69 |tlValue(|hitem, i|
|00005e50| 74 65 6d 69 64 20 3d 3d | 20 4e 4d 5f 43 4f 4e 4e |temid ==| NM_CONN|
|00005e60| 20 3f 20 31 20 3a 20 30 | 29 3b 0d 09 47 65 74 44 | ? 1 : 0|);..GetD|
|00005e70| 49 74 65 6d 28 64 6c 6f | 67 2c 20 4e 4d 5f 53 45 |Item(dlo|g, NM_SE|
|00005e80| 52 44 41 2c 20 26 74 79 | 70 65 2c 20 26 68 69 74 |RDA, &ty|pe, &hit|
|00005e90| 65 6d 2c 20 26 72 65 63 | 74 29 3b 0d 09 53 65 74 |em, &rec|t);..Set|
|00005ea0| 43 74 6c 56 61 6c 75 65 | 28 68 69 74 65 6d 2c 20 |CtlValue|(hitem, |
|00005eb0| 69 74 65 6d 69 64 20 3d | 3d 20 4e 4d 5f 53 45 52 |itemid =|= NM_SER|
|00005ec0| 44 41 20 3f 20 31 20 3a | 20 30 29 3b 0d 09 47 65 |DA ? 1 :| 0);..Ge|
|00005ed0| 74 44 49 74 65 6d 28 64 | 6c 6f 67 2c 20 4e 4d 5f |tDItem(d|log, NM_|
|00005ee0| 53 45 52 44 42 2c 20 26 | 74 79 70 65 2c 20 26 68 |SERDB, &|type, &h|
|00005ef0| 69 74 65 6d 2c 20 26 72 | 65 63 74 29 3b 0d 09 53 |item, &r|ect);..S|
|00005f00| 65 74 43 74 6c 56 61 6c | 75 65 28 68 69 74 65 6d |etCtlVal|ue(hitem|
|00005f10| 2c 20 69 74 65 6d 69 64 | 20 3d 3d 20 4e 4d 5f 53 |, itemid| == NM_S|
|00005f20| 45 52 44 42 20 3f 20 31 | 20 3a 20 30 29 3b 0d 09 |ERDB ? 1| : 0);..|
|00005f30| 47 65 74 44 49 74 65 6d | 28 64 6c 6f 67 2c 20 4e |GetDItem|(dlog, N|
|00005f40| 4d 5f 54 43 50 2c 20 26 | 74 79 70 65 2c 20 26 68 |M_TCP, &|type, &h|
|00005f50| 69 74 65 6d 2c 20 26 72 | 65 63 74 29 3b 0d 09 53 |item, &r|ect);..S|
|00005f60| 65 74 43 74 6c 56 61 6c | 75 65 28 68 69 74 65 6d |etCtlVal|ue(hitem|
|00005f70| 2c 20 69 74 65 6d 69 64 | 20 3d 3d 20 4e 4d 5f 54 |, itemid| == NM_T|
|00005f80| 43 50 20 3f 20 31 20 3a | 20 30 29 3b 0d 7d 0d 0d |CP ? 1 :| 0);.}..|
|00005f90| 0d 2f 2a 20 73 65 74 20 | 74 68 65 20 62 75 74 74 |./* set |the butt|
|00005fa0| 6f 6e 20 73 65 6c 65 63 | 74 65 64 20 61 6e 64 20 |on selec|ted and |
|00005fb0| 72 65 73 65 74 20 74 68 | 65 20 6f 74 68 65 72 73 |reset th|e others|
|00005fc0| 3b 20 20 2a 2f 0d 0d 6e | 6d 74 65 72 6d 62 75 74 |; */..n|mtermbut|
|00005fd0| 73 65 74 28 64 6c 6f 67 | 2c 20 69 74 65 6d 69 64 |set(dlog|, itemid|
|00005fe0| 29 0d 44 69 61 6c 6f 67 | 50 74 72 20 64 6c 6f 67 |).Dialog|Ptr dlog|
|00005ff0| 3b 0d 73 68 6f 72 74 20 | 69 74 65 6d 69 64 3b 0d |;.short |itemid;.|
|00006000| 7b 0d 09 73 68 6f 72 74 | 09 74 79 70 65 3b 0d 09 |{..short|.type;..|
|00006010| 52 65 63 74 20 72 65 63 | 74 3b 0d 09 48 61 6e 64 |Rect rec|t;..Hand|
|00006020| 6c 65 20 68 69 74 65 6d | 3b 0d 0d 09 65 6d 64 70 |le hitem|;...emdp|
|00006030| 2d 3e 63 6f 6e 66 63 68 | 61 6e 67 65 64 20 3d 20 |->confch|anged = |
|00006040| 54 52 55 45 3b 0d 0d 09 | 2f 2a 20 73 65 74 20 6f |TRUE;...|/* set o|
|00006050| 6e 6c 79 20 6f 6e 65 20 | 72 61 64 69 6f 20 62 75 |nly one |radio bu|
|00006060| 74 74 6f 6e 20 66 6f 72 | 20 65 6d 75 6c 61 74 69 |tton for| emulati|
|00006070| 6f 6e 3a 20 20 61 75 74 | 6f 2c 20 76 74 31 30 30 |on: aut|o, vt100|
|00006080| 2c 20 33 32 37 30 2c 20 | 68 31 39 20 2a 2f 0d 09 |, 3270, |h19 */..|
|00006090| 0d 09 47 65 74 44 49 74 | 65 6d 28 64 6c 6f 67 2c |..GetDIt|em(dlog,|
|000060a0| 20 4e 4d 5f 45 4d 41 55 | 54 4f 4d 41 54 49 43 2c | NM_EMAU|TOMATIC,|
|000060b0| 20 26 74 79 70 65 2c 20 | 26 68 69 74 65 6d 2c 20 | &type, |&hitem, |
|000060c0| 26 72 65 63 74 29 3b 0d | 09 53 65 74 43 74 6c 56 |&rect);.|.SetCtlV|
|000060d0| 61 6c 75 65 28 68 69 74 | 65 6d 2c 20 69 74 65 6d |alue(hit|em, item|
|000060e0| 69 64 20 3d 3d 20 4e 4d | 5f 45 4d 41 55 54 4f 4d |id == NM|_EMAUTOM|
|000060f0| 41 54 49 43 20 3f 20 31 | 20 3a 20 30 29 3b 0d 09 |ATIC ? 1| : 0);..|
|00006100| 0d 09 47 65 74 44 49 74 | 65 6d 28 64 6c 6f 67 2c |..GetDIt|em(dlog,|
|00006110| 20 4e 4d 5f 56 54 31 30 | 30 2c 20 26 74 79 70 65 | NM_VT10|0, &type|
|00006120| 2c 20 26 68 69 74 65 6d | 2c 20 26 72 65 63 74 29 |, &hitem|, &rect)|
|00006130| 3b 0d 09 53 65 74 43 74 | 6c 56 61 6c 75 65 28 68 |;..SetCt|lValue(h|
|00006140| 69 74 65 6d 2c 20 69 74 | 65 6d 69 64 20 3d 3d 20 |item, it|emid == |
|00006150| 4e 4d 5f 56 54 31 30 30 | 20 3f 20 31 20 3a 20 30 |NM_VT100| ? 1 : 0|
|00006160| 29 3b 0d 0d 09 47 65 74 | 44 49 74 65 6d 28 64 6c |);...Get|DItem(dl|
|00006170| 6f 67 2c 20 4e 4d 5f 56 | 54 31 30 32 2c 20 26 74 |og, NM_V|T102, &t|
|00006180| 79 70 65 2c 20 26 68 69 | 74 65 6d 2c 20 26 72 65 |ype, &hi|tem, &re|
|00006190| 63 74 29 3b 0d 09 53 65 | 74 43 74 6c 56 61 6c 75 |ct);..Se|tCtlValu|
|000061a0| 65 28 68 69 74 65 6d 2c | 20 69 74 65 6d 69 64 20 |e(hitem,| itemid |
|000061b0| 3d 3d 20 4e 4d 5f 56 54 | 31 30 32 20 3f 20 31 20 |== NM_VT|102 ? 1 |
|000061c0| 3a 20 30 29 3b 0d 0d 09 | 47 65 74 44 49 74 65 6d |: 0);...|GetDItem|
|000061d0| 28 64 6c 6f 67 2c 20 4e | 4d 5f 33 32 37 38 2c 20 |(dlog, N|M_3278, |
|000061e0| 26 74 79 70 65 2c 20 26 | 68 69 74 65 6d 2c 20 26 |&type, &|hitem, &|
|000061f0| 72 65 63 74 29 3b 0d 09 | 53 65 74 43 74 6c 56 61 |rect);..|SetCtlVa|
|00006200| 6c 75 65 28 68 69 74 65 | 6d 2c 20 69 74 65 6d 69 |lue(hite|m, itemi|
|00006210| 64 20 3d 3d 20 4e 4d 5f | 33 32 37 38 20 3f 20 31 |d == NM_|3278 ? 1|
|00006220| 20 3a 20 30 29 3b 0d 0d | 09 47 65 74 44 49 74 65 | : 0);..|.GetDIte|
|00006230| 6d 28 64 6c 6f 67 2c 20 | 4e 4d 5f 48 31 39 2c 20 |m(dlog, |NM_H19, |
|00006240| 26 74 79 70 65 2c 20 26 | 68 69 74 65 6d 2c 20 26 |&type, &|hitem, &|
|00006250| 72 65 63 74 29 3b 0d 09 | 53 65 74 43 74 6c 56 61 |rect);..|SetCtlVa|
|00006260| 6c 75 65 28 68 69 74 65 | 6d 2c 20 69 74 65 6d 69 |lue(hite|m, itemi|
|00006270| 64 20 3d 3d 20 4e 4d 5f | 48 31 39 20 3f 20 31 20 |d == NM_|H19 ? 1 |
|00006280| 3a 20 30 29 3b 0d 0d 09 | 2f 2a 20 73 65 74 20 74 |: 0);...|/* set t|
|00006290| 68 65 20 64 69 73 61 62 | 6c 65 74 65 72 6d 20 61 |he disab|leterm a|
|000062a0| 72 72 61 79 20 61 63 63 | 6f 72 64 69 6e 67 6c 79 |rray acc|ordingly|
|000062b0| 20 2a 2f 0d 09 69 66 20 | 28 69 74 65 6d 69 64 20 | */..if |(itemid |
|000062c0| 3d 3d 20 4e 4d 5f 45 4d | 41 55 54 4f 4d 41 54 49 |== NM_EM|AUTOMATI|
|000062d0| 43 29 20 7b 0d 09 09 2f | 2a 20 65 6e 61 62 6c 65 |C) {.../|* enable|
|000062e0| 20 61 6c 6c 20 74 68 65 | 20 74 65 72 6d 69 6e 61 | all the| termina|
|000062f0| 6c 73 20 2a 2f 0d 09 09 | 65 6d 64 70 2d 3e 64 69 |ls */...|emdp->di|
|00006300| 73 61 62 6c 65 74 65 72 | 6d 5b 54 45 52 4d 5f 56 |sableter|m[TERM_V|
|00006310| 54 31 30 30 5d 20 3d 20 | 46 41 4c 53 45 3b 0d 09 |T100] = |FALSE;..|
|00006320| 09 65 6d 64 70 2d 3e 64 | 69 73 61 62 6c 65 74 65 |.emdp->d|isablete|
|00006330| 72 6d 5b 54 45 52 4d 5f | 56 54 31 30 32 5d 20 3d |rm[TERM_|VT102] =|
|00006340| 20 46 41 4c 53 45 3b 0d | 09 09 65 6d 64 70 2d 3e | FALSE;.|..emdp->|
|00006350| 64 69 73 61 62 6c 65 74 | 65 72 6d 5b 54 45 52 4d |disablet|erm[TERM|
|00006360| 5f 56 54 32 32 30 5d 20 | 3d 20 46 41 4c 53 45 3b |_VT220] |= FALSE;|
|00006370| 0d 09 09 65 6d 64 70 2d | 3e 64 69 73 61 62 6c 65 |...emdp-|>disable|
|00006380| 74 65 72 6d 5b 54 45 52 | 4d 5f 33 32 37 30 5d 20 |term[TER|M_3270] |
|00006390| 3d 20 46 41 4c 53 45 3b | 0d 09 09 65 6d 64 70 2d |= FALSE;|...emdp-|
|000063a0| 3e 64 69 73 61 62 6c 65 | 74 65 72 6d 5b 54 45 52 |>disable|term[TER|
|000063b0| 4d 5f 48 31 39 5d 20 3d | 20 46 41 4c 53 45 3b 0d |M_H19] =| FALSE;.|
|000063c0| 09 7d 0d 09 65 6c 73 65 | 20 7b 0d 09 09 2f 2a 20 |.}..else| {.../* |
|000063d0| 65 6e 61 62 6c 65 20 6f | 6e 6c 79 20 6f 6e 65 20 |enable o|nly one |
|000063e0| 74 65 72 6d 69 6e 61 6c | 20 2a 2f 0d 09 09 65 6d |terminal| */...em|
|000063f0| 64 70 2d 3e 64 69 73 61 | 62 6c 65 74 65 72 6d 5b |dp->disa|bleterm[|
+--------+-------------------------+-------------------------+--------+--------+
Only 25.0 KB of data is shown above.